Android Camera Image Test Suite (ITS) is part of Android Compatibility Test Suite (CTS) Verifier and includes tests that verify image content. As of CTS 7.0_r8, CTS Verifier supports ITS test automation via Camera ITS-in-a-box; support for manual tests continues to ensure coverage for all Android device form factors.
ITS-in-a-box brings the following benefits:
ITS-in-a-box consists of a plastic box that is laser cut from computer-aided design (CAD) drawings, a chart tablet, and a device under test (DUT). To get started with the Camera ITS-in-a-box:
This section provides step-by-step instructions for setting up a Pixel C tablet for use with the CameraITS software.
Note: The CameraITS python scripts
automatically set the following options on the tablet for you:
Settings > Display > Sleep > After 30 minutes of inactivity
Adaptive brightness > OFF
Enable options |
|
---|---|
Disable options |
|
$ adb devices
to list
available devices. To determine device_id
and
chart_id
, plug and unplug devices and observe the devices that
connect and disconnect.python tools/run_all_tests.py device=$device_id camera=0 chart=$chart_id scenes=2,3Scenes 2 and 3 require the tablet to display an image, so the tablet prompts you to "Allow Drive to access photos, media, and files on your device?". Clear this prompt (and prevent future prompts) by pressing Allow.
tools/run_all_tests.py
and confirm that scenes
change automatically as script cycles through different scenes. While most
tests will FAIL (as the camera is not pointed at the chart), you can verify the
tablet correctly cycles through the scenes without displaying any prompts or
other pop-ups on the screen.Before running the ITS-in-a-box, ensure your test setup includes the following hardware and software:
adb -s FA6BM0305016 install -r android-cts-verifier/CtsVerifier.apk
adb -s FA6BM0305439 install -r android-cts-verifier/CtsVerifier.apk
To run scenes 0-4 on the front and back camera in parallel:
cd android-cts-verifier/CameraITS
. build/envsetup.sh
python tools/run_parallel_tests.py device0=FA6BM0305016 device1=FA6BM0305439 chart=5811000011
Examples:
You can retry scenes for both front and back cameras or a single camera:
python tools/run_parallel_tests.py device0=FA6BM0305016 device1=FA6BM0305439 chart=5811000011 scenes=3,4
python tools/run_all_tests.py device=FA6BM0305016 chart=5811000011 camera=1 scenes=3,4
Scene 5 requires special setup with specific lighting (for details, refer to CameraITS.pdf in the CTS Verifier download). You can run Scene 5 separately (outside of the box) to test two devices in parallel.
python tools/run_parallel_tests.py device0=FA6BM0305016 device1=FA6BM0305439 chart=5811000011 scenes=5
python tools/run_all_tests.py device=FA6BM0305016 camera=0 scenes=5
python tools/run_all_tests.py device=FA6BM0305016 camera=1 scenes=5
You can view results during testing and save the completed results as a report.
run_parallel_tests
prints results only after Camera-Scene tests
have finished, so to view results during test execution you must use Android
Device Monitor or adb logcat
to verify progress and/or view
screenshots.adb -s FA6BM0305016 logcat -v timeExample screenshots command:
adb -s FA6BM0305016 shell screencap -p /sdcard/screencap.png
adb -s FA6BM0305016 pull /sdcard/screencap.png
display ./screencap.png
adb -s FA6BM0305016 pull /sdcard/verifierReports