[[["容易理解","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 (世界標準時間)。"],[],[],null,["# CTS Verifier test guidance\n\nDevice administration\n---------------------\n\nTest: Cts Verifier \\\u003e Device Administration \\\u003e Device Admin Tapjacking Test\n\n- `com.android.cts.verifier.admin.tapjacking.DeviceAdminTapjackingTestActivity`\n\nThe test is open to interpretation if it behaves as expected or not.\nButtons can be tapped through the overlay but maybe produce an unclear\ndescription.\n\nThe button to activate the admin should be disabled and should not register\nany taps.\n\nIt isn't possible to activate the device admin app but a toast is shown\n**Because another app is displaying on top of these options, Settings can't\nrespond to your action.** Hence, the tap is registered and it is still possible\nto tap cancel and press **Uninstall app**.\n\nBelow are the expected results for Step 3.\n\n|--------------------------------|---------------------------------------------------|----------------------------------------------------|\n| | | |\n| 3. Tap \\[ENABLE DEVICE ADMIN\\] | 3.1. \\[Active this device admin app\\] is enabled. | 3.2. \\[Active this device admin app\\] is disabled. |\n\n**Figure 1.** Expected results for the device administration test.\n\nCompanion device test\n---------------------\n\nThe companion device test is `com.android.cts.verifier.companion.CompanionDeviceTestActivity`.\n\nIt may be unclear if the test has finished correctly after selecting\nthe device in the list and pressing **OK**.\n\nSee below for the expected results.\n\n|---------------|--------------------|-----------------|\n| | | |\n| 1. Tap \\[GO\\] | 2. Tap a BT device | 3. Tap \\[Pass\\] |\n\n**Figure 2.** Expected results for the companion device test.\n\nVoicemail broadcast test\n------------------------\n\nThe voicemail broadcast test is `com.android.cts.verifier.voicemail.VoicemailBroadcastActivity`.\n\nTo send a voicemail to the phone, call the device, decline the call on the\ndevice, and leave a voicemail.\n\nA visual voicemail is a way to send the device audio data and detailed\ninformation for incoming voicemails, instead of just sending the [Message\nWaiting Indicator\\*\\* (MWI) SMS](http://www.omtp.org/OMTP_VVM_Specification_v1_3_Final.pdf).\n\nThe test is testing behavior regarding receiving the MWI, and if\nvisual voicemail is being used, the carrier might not send the MWI\nand interfere with the test, thus it must be disabled.\n\nUSB accessory/device test\n-------------------------\n\n**Figure 3.** Instructions for the voicemail broadcast test.\n\nSpecific instructions to avoid flaky behavior:\n\n1. Install the CtsVerifier.apk on the DUT\n2. Install the CtsVerifierUSBCompanion.apk on the Pixel\n3. Make sure all USB cables are disconnected\n4. Start the CtsVerifierUSBCompanion on the Pixel and select the accessory test companion\n5. Start the CtsVerifier on the DUT and select the USB Accessory test\n6. Connect the OTG-Adapter to the Pixel and then connect the DUT via a USB-A(male)-C cable\n7. Approve the connection dialogs in the following order:\n - Pixel\n - DUT\n - Pixel\n - Wait until test completes\n\nDynamic sensor discovery test\n-----------------------------\n\nEach device maker can decide whether or not to support the API\n([`isDynamicSensorDiscoverySupported`](https://developer.android.com/reference/android/hardware/SensorManager.html#isDynamicSensorDiscoverySupported())).\n\nIf a device supports the API, the device maker needs to source an external\nsensor that can be used to pass the test. The device maker will need to locate\na device to connect to their device to test dynamic sensors.\n\nIf the device maker isn't able to locate a device, the following setup can be used.\n\n1. Purchase TI EK-TM4C123GXL development board. \n [Option 1](https://www.ti.com/tool/EK-TM4C123GXL) \n [Option 2](https://www.google.com/url?q=https://www.mouser.com/ProductDetail/Texas-Instruments/EK-TM4C123GXL&sa=D&source=editors&ust=1676568461431133&usg=AOvVaw0J6fkMms-S1XT3FnSJY_dH)\n2. Download and install lm4tools.\n\n For linux/mac execute:\n `cd /tmp\n git clone https://github.com/utzig/lm4tools.git\n cd lm4tools\n make\n sudo PREFIX=/usr make install`\n\n For windows, you can use [LMFlash](https://www.ti.com/tool/LMFLASHPROGRAMMER)\n directly from TI which allows you to flash from a GUI.\n3. Retrieve a Google provided binary called \n\n usb_sensor_dummy_accel.bin.\n\n4. Flip the switch present on the board to the DEBUG mode and plug a USB micro\n cable into the port labeled DBG.\n\n5. Run the following command:\n `lm4flash -v -E usb_accel_dummy.bin`\n\n NOTE: If there's a permission issue, please run with `sudo`\n6. After flashing completes, unplug the USB micro cable from the DBG port,\n flip the switch used earlier back to DEVICE, and then plug one end of the\n USB micro cable into the USB slot labeled DEVICE. The other end of the cable\n should be plugged directly into your device.\n\n7. Now you can execute this CTS-V test which should be able to discover and\n use the device you just plugged in as a fake accelerometer.\n\nDevice admin uninstall test\n---------------------------\n\nThis test may require manual install of `CtsEmptyDeviceAdmin.apk` on the device\nfirst from a host via `adb`.\n\nFor example, `adb install CtsEmptyDeviceAdmin.apk`.\n\nUse **CTS Verifier** \\\u003e **Device Administration** \\\u003e **Device Admin\nUninstall Test**.\n\nIt should detect that the app is installed and go through other steps.\n\nCapture Content for Notes Tests\n-------------------------------\n\nStarting with Android 14, if an OEM chooses to enable\nthe `NOTES` role, the OEM device must pass the new Capture Content for Notes\nCTS-V test.\n\nThe Capture Content for Notes test is located in [`CaptureContentForNotesVerifierActivity.java`](https://android.googlesource.com/platform/cts/+/refs/heads/android16-release/apps/CtsVerifier/src/com/android/cts/verifier/capturecontentfornotes/CaptureContentForNotesVerifierActivity.java)\nand found under the **FEATURES** category as shown in the following figure:\n\n**Figure 4.** Capture Content for Notes test in CTS-V suite.\n\nThe Capture Content for Notes test tests the following APIs:\n\n- [`Intent#ACTION_LAUNCH_CAPTURE_CONTENT_ACTIVITY_FOR_NOTE`](https://developer.android.com/reference/android/content/Intent#ACTION_LAUNCH_CAPTURE_CONTENT_ACTIVITY_FOR_NOTE)\n- [`Intent#EXTRA_CAPTURE_CONTENT_FOR_NOTE_STATUS_CODE`](https://developer.android.com/reference/android/content/Intent#EXTRA_CAPTURE_CONTENT_FOR_NOTE_STATUS_CODE)\n- [`android.permission.LAUNCH_CAPTURE_CONTENT_ACTIVITY_FOR_NOTE`](https://developer.android.com/reference/android/Manifest.permission#LAUNCH_CAPTURE_CONTENT_ACTIVITY_FOR_NOTE)\n- [`StatusBarManager#canLaunchCaptureContentActivityForNote`](https://developer.android.com/reference/android/app/StatusBarManager#canLaunchCaptureContentActivityForNote(android.app.Activity))\n\nBefore executing the Capture Content for Notes test, do the following:\n\n1. Ensure that the device has the `NOTES` role enabled.\n If you see a **Notes** option under **Default apps** in the **Apps** Settings\n window, the `NOTES` role is enabled.\n\n | **Note:** The test lets the user skip the test if the `NOTES` role is disabled.\n2. If the device supports the `NOTES` role, start the default note-taking app in\n a floating multitasking window. You can do this through a widget shortcut\n entry point on the home screen or a peripheral device action such as a button\n on a stylus.\n\n | **Note:** Depending on OEM customizations, the Capture Content for Notes test might require a stylus or other such hardware to trigger the system note-taking integrations. OEMs can also allow using `adb` commands to mimic the actions that trigger the system note-taking integration.\n3. Install `CtsDefaultNotesApp` as described in [`README`](https://android.googlesource.com/platform/cts/+/refs/heads/android16-release/apps/NotesApp/README).\n\nWhile running the test, use the following guidelines:\n\n- If the `NOTES` role is disabled, the test list is empty and the test lets users skip the test. Tap the green pass button to skip the test.\n- If the `NOTES` role is enabled, the green pass button is disabled and\n tests are present in the test list as shown in the following figure:\n\n **Figure 5.** Capture Content for Notes test when the `NOTES` role is enabled.\n\n Execute the Capture Content for Notes test suite as follows:\n 1. Go through each test and follow the instructions.\n\n | **Note:** Some tests might ask users to launch the `CtsDefaultNotesApp` in a specific windowing mode using OEM-specific gestures and to set up admin policies.\n 2. Tap the appropriate button:\n\n - Tap the green pass button to record a success. The green pass button is enabled when all the tests pass.\n - Tap the red fail button to record a failure.The red fail button is enabled if there is a failed test."]]