The Compatibility Test Suite Verifier (CTS Verifier) is a supplement to the CTS available for download. CTS Verifier provides tests for APIs and functions that cannot be tested on a stationary device without manual input (e.g. Audio quality, accelerometer, etc).
The Android Compatibility Test Suite Verifier (CTS Verifier) supplements theCompatibility Test Suite (CTS). While CTS checks APIs and functions that can beautomated, CTS Verifier provides tests for APIs and functions that can't betested on a stationary device without manual input, such as audio quality,touchscreen, accelerometer, and camera.
Requirements
Before running CTS Verifier, ensure that you have the following equipment:
- Android device that has verified Android API compatibility by successfullypassing the CTS. This is the device under test (DUT).
- Linux computer with USB 2.0 compatible port. All connections to the DUT gothrough this port.
- Second Android device with a known compatible Bluetooth, Wi-Fi direct, andNFC host card emulation (HCE) implementation.
- A Wi-Fi router configured with access point name and password. The routershould have the ability to disconnect from the internet, but not powered off.
Setting up
To setup the CTS Verifier testing environment:
- On the Linux computer:
- Install the AndroidStudio.
- Download theCTS Verifier APK for theversion of Android to test.
- Connect the DUT to the Linux computer.
- From a terminal on the Linux computer, install
CtsVerifier.apk
on the DUT. - For Android 10 and higher, run the following command to givepermission to the app to create the report.
- Ensure that the DUT has the system data and time set correctly.
Running
Launch the CTS Verifier application by tapping the CTS Verifier icon on the DUT.
The app displays several test sets available for manual verification.
Each test contains a set of common elements (Info, Pass, Fail) at the bottom of the screen.
- Info (?). Tap to display test instructions. Also appearsautomatically the first time a test is opened.
- Pass (✓). Tap if the DUT meets the test requirements perthe Info instructions.
- Fail (!). Tap if the DUT doesn't meet the testrequirements per the Info instructions.
Compatibility Test Suite Cts User Manual 2016
Note: In some tests, pass/fail isdetermined automatically.Some tests, such as the USB accessory mode and camera calibration test,require additional test setup and instructions as detailed in the followingsections.
Testing USB accessory mode for 8.0 and above
Testing USB accessory mode for 7.x and below
Compatibility Test Suite Cts User Manual Online
The USB Accessory test requires a Linux computer to run the USB desktopmachine (host) program.
Compatibility Test Suite Cts User Manual Guide
- Connect the DUT to the Linux computer.
- On the computer, execute the
cts-usb-accessory
program from theCTS Verifier package: - Wait for a popup message to appear on the DUT, then selectOK.
Figure 6. USB accessory test - Go to the USB Accessory Test in the CTS Verifier application on DUT.
- On the computer, review the output from the console. Example output:
Calibrating camera field of view
Use the field of view calibration procedure to quickly determine the devicefield of view with moderate accuracy.
- Set up the test environment:
- Print thecalibration-pattern.pdftarget file on 11” x 17” or A3 size paper.
- Mount the printed pattern on a rigid backing.
- Orient the camera device and the printed target as shown below.
Figure 7. Camera printed target
- Set the target width:
- Measure the distance (in centimeters) between the solid lines on the targetpattern to account for printing inaccuracies (~38 cm).
- Start the calibration application.
- Press the setup button and select Marker distance.
- Measure and enter the distance to the target pattern (~100 cm).
- Press the back button to return to the calibration preview.
- Verify that the device and target are placed as shown in the figure and thecorrect distances have been entered into the setup dialog. The preview displays the image with avertical line overlaid onto it; this line should alignwith the center line of the target pattern. The transparent grid can be usedwith the other vertical lines to ensure that the optical axis is orthogonal tothe target.
- Run the calibration test:
- Select an image resolution (using selector at the bottom left), then tap thescreen to take a photo. The test enters calibration mode and displays the photowith two vertical lines overlaid onto the image.
- Determine accuracy:
- If the lines align with the vertical lines on the target pattern within afew centimeters, the reported field of view for the selected resoultion is accurate.
- If the lines don't align, the reported field of view is inaccurate. Tocorrect this, adjust the slider at the bottom of the screen until the overlay alignswith the target pattern as closely as possible. When the overlay and the targetpattern image are aligned, the displayed field of view is a closeapproximation to the correct value. The reported field of view should bewithin +/-1 degree of the calibration value.
- Press back button and repeat the calibration test for all image resolutionssupported by the DUT.
Exporting results
Compatibility Test Suite Cts User Manual Download
After all tests complete, you can save the results as a report and download themto a computer. Report names are automatically time-stamped based on the DUTsystem time.
Compatibility Test Suite (cts) User Manual
- Tap the Save (disk) icon.
Figure 8. CTS Verifier Save icon Note: Android 7.0 and higher don't includethe preview feature. - Wait for the popup message to display the path to the saved report (for example,
/sdcard/verifierReports/ctsVerifierReport-date-time.zip
), thenrecord the path.Figure 9. CTS Verifier path to savedreport - Connect the DUT to the Linux computer.
- From the Android SDK installation on the Linux computer, download reportsfrom the connected device using
adb shell content read
oradb pullCTSVerifierReportPath
.- For Android 7.x and higher, download all reports using:
- For Android 6.0 and lower, download all reports using:
For Android 10 and higher, implementing Automotive and devices runningin secondary user, download thelatest report using:
Note: Useadb shell am get-current-user
toget the CURRENT_USER ID.To list all reports available in the connected device:
To download a report from the list, you can specify the Row ID or filename. For example:
- To clear pass/fail results, select the results in the CTS Verifier app andselect Menu > Clear.