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). You can use the wide field of view (WFoV) ITS-in-a-box, which is capable of testing both WFoV (FoV > 90 degrees) and RFoV (FoV < 90 degrees) cameras, or the regular field of view (RFoV) ITS-in-a-box.
To get started with the Camera ITS-in-a-box:
This section provides step-by-step instructions for setting up a tablet for use with the CameraITS software. These instructions use a Pixel C as an example tablet. For information on tablet requirements and recommendations, see Tablet requirements.
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 CTS Verifier, which you can download at Compatibility Test Suite Downloads). 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
Tablets must have a display size of around 10 inches with a screen resolution
greater than 2000 x 1500 pixels. The DISPLAY_LEVEL
value must be
set in
CameraITS/tools/wake_up_screen.py
according to the tablet model.
The table below lists the values for recommended tablets.
Recommended tablets for ITS testing are shown below:
Device | Display size (inches) |
Display size (pixels) |
Tablet dimensions (inches) |
DISPLAY_LEVEL | OS |
---|---|---|---|---|---|
Asus Zen Pad 3 | 9.7 | 2048 x 1536 | 9.47 x 6.44 x 0.28 | 192 | Android 6.0 |
Huawei Mediapad m5 | 10.8 | 2560 x 1600 | 10.18 x 6.76 x 0.29 | 192 | Android 8.0 |
Pixel C | 10.2 | 2560 x 1800 | 9.53 x 7.05 x 0.28 | 96 | Android 8.0 |
Samsung S3 | 9.7 | 2048 x 1536 | 10.76 x 6.65 x 0.24 | 192 | Android 7.0 |
Sony Xperia Z4 | 10.1 | 2560 x 1600 | 10 x 6.57 x 0.24 | 192 | Android 7.0 |