ImeTest fails locally due to file read permission |
|||||
Issue descriptionImeTest needs to load an HTML file (INPUT_FORM_HTML = "content/test/data/android/input/input_forms.html";) on the external storage. It may not have the permission to read files when content shell is installed on the phone for the first time. In that case, the test fails. To reproduce this bug locally, we can go to Settings->Apps->Content Shell->Permissions->Storage, disable the permission, and run the test. I encountered it locally when I reinstalled Android System and ran the test for the first time. I've never seen it on trybot.
,
Sep 29 2016
+cc rnephew@ who wrote https://cs.chromium.org/chromium/src/third_party/catapult/devil/devil/android/device_utils.py?q=GrantPermissions&l=739 which I think is the code involved in setting the permissions. Maybe it's a race condition between setting the permission and starting the test activity? Note yabinh@ has a patch to more clearly report the error at https://codereview.chromium.org/2380593002/ (though not a fix for underlying problem yet).
,
Dec 8 2016
rnephew@, can you take a look at this bug?
,
Dec 8 2016
,
Dec 8 2016
Output would be nice. Logcat from the fail would be even better. I'm remote this week so wont be able to run it locally easily until next week. How are you installing the apk? How are you running the test (test runner or the wrapper scripts)? When the test runner installs the apk it sets all permissions that are set in the manifest. Usually when there are problems with permissions it means somewhere the app data is getting cleared and the permissions are not being regranted.
,
Dec 9 2016
The script I used to build and run the test is: . build/android/envsetup.sh && gn gen out_android_gn/Debug --args='target_os="android" is_component_build=true symbol_level=1 use_goma=true enable_incremental_javac=true google_play_services_type="public" is_debug=true disable_incremental_isolated_processes=true ' && ninja -C out_android_gn/Debug -j1000 -l20 content_shell_apk_incremental content_shell_test_apk_incremental && out_android_gn/Debug/bin/install_content_shell_apk_incremental && out_android_gn/Debug/bin/run_content_shell_test_apk_incremental --num_retries=0 --test-filter ImeTest.testImeCopy
,
Aug 2
|
|||||
►
Sign in to add a comment |
|||||
Comment 1 by yabinh@chromium.org
, Sep 29 2016