Android 공급업체 테스트 모음(VTS)에서는 다음 항목에 관한 광범위한 테스트를 제공합니다.
커널
하드웨어 추상화 계층(HAL)
VTS는 데스크톱 컴퓨터에서 실행되며 연결된 기기나 에뮬레이터에서 직접 테스트 사례를 실행합니다. CTS와 마찬가지로, VTS는 다음과 같은 주요 소프트웨어 구성요소를 사용하는 자동화된 테스트 모음입니다.
VTS Trade Federation 테스트 하네스는 호스트 머신에서 실행되며 테스트 실행을 관리합니다. 여러 테스트 대상 기기 (DUT)에서 샤딩을 구성할 수 있는 기능을 제공합니다. 또한 모음 재시도 기능을 사용하여 전체 테스트 모음이 아니라 실패한 테스트만 재시도할 수 있으며, 이로 인해 재실행 시간이 크게 줄어듭니다.
개별 테스트 사례는 DUT에서 실행됩니다. 테스트 사례는 GTest 형식 테스트, 커널 테스트 또는 Java로 작성된 JUnit 형식 테스트일 수 있습니다.
테스트 유형
VTS 테스트의 다양한 유형은 다음 섹션에 설명되어 있습니다.
GTest 형식의 테스트
VTS의 테스트 대부분은 HAL 구현을 확인하는 GTest 형식의 테스트입니다. 테스트는 C++로 작성하며 기기에서 실행됩니다. 일반적인 VTS GTest는 지정된 인터페이스의 각 인스턴스를 통해 반복하고 인스턴스의 모든 테스트 사례를 실행합니다. 예는 VtsHalHealthStorageV1_0TargetTest를 참고하세요.
Linux 커널 테스트
Kselftest(external/linux-kselftest)는 tools/testing/selftests의 Linux 커널 저장소 내에 포함된 테스트 컬렉션으로, 23개의 테스트가 VTS에 포함되어 ARM에서 실행됩니다.
Linux 테스트 프로젝트(external/ltp) 테스트는 Linux 커널의 신뢰성, 견고성, 안정성을 검증합니다.
JUnit 형식의 테스트
VTS에서 호스트 기반의 소규모 테스트 집합은 JUnit 형식의 테스트입니다(예: KernelApiSysfsTest).
Java 테스트는 BaseHostJUnit4Test로 구현되며, 이는 테스트 기기와 연결되고 유효성 검사를 실행하기 위해 셸 명령어를 실행할 수 있습니다.
독립형 Python3 테스트
vts_treble_sys_prop_test와 같은 일부 VTS 테스트는 Python3로 작성됩니다. Python 기반 테스트는 unittest.TestCase로 구현되며 각 테스트 사례는 셸 명령어를 통해 기기와 상호작용할 수 있습니다.
이 페이지에 나와 있는 콘텐츠와 코드 샘플에는 콘텐츠 라이선스에서 설명하는 라이선스가 적용됩니다. 자바 및 OpenJDK는 Oracle 및 Oracle 계열사의 상표 또는 등록 상표입니다.
최종 업데이트: 2025-07-27(UTC)
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["필요한 정보가 없음","missingTheInformationINeed","thumb-down"],["너무 복잡함/단계 수가 너무 많음","tooComplicatedTooManySteps","thumb-down"],["오래됨","outOfDate","thumb-down"],["번역 문제","translationIssue","thumb-down"],["샘플/코드 문제","samplesCodeIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-07-27(UTC)"],[],[],null,["# Vendor Test Suite (VTS) and infrastructure\n\nThe Android Vendor Test Suite (VTS) provides\nextensive testing on the following:\n\n- Kernel\n- Hardware abstraction layer (HAL)\n\nVTS runs on a\ndesktop machine and executes test cases directly on attached devices or\non the emulators. Similar to [CTS](/docs/compatibility/cts), VTS is\nan automated test suite that uses the following major software components:\n\n- The VTS [Trade Federation](/docs/core/tests/tradefed) test harness runs on your host machine and manages test execution. It offers the ability to [Configure sharding](/docs/core/tests/tradefed/testing/through-suite/android-test-tuning) across multiple devices under test (DUTs). You can also use the [Suite Retry](/devices/tech/test_infra/tradefed/testing/through-suite/suite-retry) feature to retry only the failures rather than the entire test suites, which greatly reduces the re-run time.\n- Individual test cases are executed on the DUT. The test cases can be GTest-style tests, kernel tests, or JUnit-style tests written in Java.\n\nTypes of tests\n--------------\n\nThe various types of VTS tests are described in the following sections.\n\n### GTest-style tests\n\nMost tests in VTS are GTest-style tests that check the HAL\nimplementation. The test is\nwritten in C++ and runs on the device. A typical VTS GTest iterates through\neach instance of a given interface, and runs all the test cases\nagainst it. Refer to [`VtsHalHealthStorageV1_0TargetTest`](https://cs.android.com/android/platform/superproject/+/android-latest-release:hardware/interfaces/health/storage/1.0/vts/functional/)\nfor an example.\n\n### Linux kernel tests\n\n- Kselftest ([external/linux-kselftest](https://github.com/torvalds/linux/tree/master/tools/testing/selftests/kselftest))\n is a collection of tests included within the Linux kernel repository\n at `tools/testing/selftests`, of which 23 are included in VTS to run on ARM.\n\n- Linux Test Project ([external/ltp](https://cs.android.com/android/platform/superproject/+/android-latest-release:external/ltp/))\n tests validate the reliability, robustness, and stability of the Linux kernel.\n\n### JUnit-style tests\n\nA small set of host-driven tests in VTS are JUnit-style tests, for example,\n[`KernelApiSysfsTest`](https://cs.android.com/android/platform/superproject/+/android-latest-release:test/vts-testcase/kernel/api/sysfs/src/com/android/tests/sysfs/KernelApiSysfsTest.java).\nThe Java tests are implemented as\n[`BaseHostJUnit4Test`](https://cs.android.com/android/platform/superproject/+/android-latest-release:tools/tradefederation/core/test_framework/com/android/tradefed/testtype/junit4/BaseHostJUnit4Test.java),\nwhich is associated with a test device and can run shell\ncommands to perform validation.\n\n### Standalone Python3 tests\n\nSome VTS tests, such as\n[`vts_treble_sys_prop_test`](https://cs.android.com/android/platform/superproject/+/android-latest-release:test/vts-testcase/security/system_property/vts_treble_sys_prop_test.py)\nare written in Python3. The\nPython-based tests are implemented as `unittest.TestCase` and each test\ncase can interact with the device through shell commands.\n| **Caution:** The Python tests aren't recommended due to limited support in the Android tree. We highly recommend writing the VTS tests as GTest, or at least as JUnit-style tests."]]