question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Issue: ViewAction closeSoftKeyboard() does ensure that soft keyboard is completely gone

See original GitHub issue

Tests always fail on real devices: Nexus7 (2012), Android 5.0.2, factory image, landscape. (Google keyboard, animations disabled) Nexus5 - Android 5.0.1 factory image, landscape. (Google keyboard, animations disabled) And Samsung S2 - Android 4.4.4 etc.

Due Google keyboard needs 50 miliseconds to be dismissed as people explain since a year ago and seems to disable animations doesn’t help… Only adding Thread.sleep(50) before the next click solves it.

Bug is already reported here: PerformException: Error performing ‘single click’ on view ViewAction closeSoftKeyboard() does ensure that soft keyboard is completely gone

If you need extra info, I can share it or you can reproduce it. You only need to use landscape mode on a nexus device and run the BasicSample.

Logcat:

com.example.android.testing.espresso.BasicSample.ChangeTextBehaviorTest > testChangeText_newActivity[Nexus 7 - 5.0.2] FAILED 
        android.support.test.espresso.PerformException: Error performing 'single click' on view 'with id: com.example.android.testing.espresso.BasicSample:id/activityChangeTextBtn'.
        at android.support.test.espresso.PerformException$Builder.build(PerformException.java:83)

com.example.android.testing.espresso.BasicSample.ChangeTextBehaviorTest > testChangeText_sameActivity[Nexus 7 - 5.0.2] FAILED 
        android.support.test.espresso.PerformException: Error performing 'single click' on view 'with id: com.example.android.testing.espresso.BasicSample:id/changeTextBt'.
        at android.support.test.espresso.PerformException$Builder.build(PerformException.java:83)
:espresso:BasicSample:app:connectedAndroidTest FAILED          

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':espresso:BasicSample:app:connectedAndroidTest'.
> There were failing tests. See the report at: file:///home/ardock/studio/projects/google/googlesamples/android-testing/espresso/BasicSample/app/build/outputs/reports/androidTests/connected/index.html
--------- beginning of system
D/PackageManager(  455): /data/app/vmdl868807800.tmp already staged; skipping copy
D/Finsky  ( 1594): [1] PackageVerificationReceiver.onReceive: Verification requested, id = 2
D/PackageManager(  455): Renaming /data/app/vmdl868807800.tmp to /data/app/com.example.android.testing.espresso.BasicSample-1
I/art     (  455): DexFile_isDexOptNeeded failed to open oat file '/data/dalvik-cache/arm/data@app@com.example.android.testing.espresso.BasicSample-1@base.apk@classes.dex' for file location '/data/app/com.example.android.testing.espresso.BasicSample-1/base.apk': Failed to open oat filename for reading: No such file or directory
I/art     (  455): DexFile_isDexOptNeeded failed to open oat file '/data/app/com.example.android.testing.espresso.BasicSample-1/arm/base.odex' for file location '/data/app/com.example.android.testing.espresso.BasicSample-1/base.apk': Failed to open oat filename for reading: No such file or directory
I/PackageManager(  455): Running dexopt on: /data/app/com.example.android.testing.espresso.BasicSample-1/base.apk pkg=com.example.android.testing.espresso.BasicSample isa=arm vmSafeMode=false
I/dex2oat ( 6252): /system/bin/dex2oat --zip-fd=6 --zip-location=/data/app/com.example.android.testing.espresso.BasicSample-1/base.apk --oat-fd=7 --oat-location=/data/dalvik-cache/arm/data@app@com.example.android.testing.espresso.BasicSample-1@base.apk@classes.dex --instruction-set=arm --instruction-set-features=default --runtime-arg -Xms64m --runtime-arg -Xmx512m
I/dex2oat ( 6252): dex2oat took 2.419s (threads: 4)
V/BackupManagerService(  455): restoreAtInstall pkg=com.example.android.testing.espresso.BasicSample token=3 restoreSet=0
V/BackupManagerService(  455): Finishing install immediately
W/Settings(  455): Setting install_non_market_apps has moved from android.provider.Settings.Global to android.provider.Settings.Secure, returning read-only value.
I/InputReader(  455): Reconfiguring input devices.  changes=0x00000010
D/Documents( 4253): Update found 7 roots in 19ms
I/UpdateIcingCorporaServi( 1101): Updating corpora: APPS=com.example.android.testing.espresso.BasicSample, CONTACTS=MAYBE
I/ConfigFetchService( 1277): PackageReceiver: Intent { act=android.intent.action.PACKAGE_ADDED dat=package:com.example.android.testing.espresso.BasicSample flg=0x4000010 cmp=com.google.android.gms/.config.ConfigFetchService$PackageReceiver (has extras) }
I/ConfigService(  902): onCreate
I/ConfigService(  902): onBind for Intent { act=com.google.android.gms.config.UPDATE pkg=com.google.android.gms } action com.google.android.gms.config.UPDATE
I/ConfigFetchService( 1277): onStartCommand Intent { act=android.intent.action.PACKAGE_ADDED dat=package:com.example.android.testing.espresso.BasicSample cmp=com.google.android.gms/.config.ConfigFetchService (has extras) }
I/ConfigFetchService( 1277): launchTask
I/ConfigService(  902): onBind returning update interface
I/ConfigService(  902): onBind for Intent { act=com.google.android.gms.config.START pkg=com.google.android.gms } action com.google.android.gms.config.START
I/ConfigService(  902): onBind returning config service
I/ConfigFetchService( 1277): service connected
I/ConfigClient( 1277): service connected
D/PackageBroadcastService( 1277): Received broadcast action=android.intent.action.PACKAGE_ADDED and uri=com.example.android.testing.espresso.BasicSample
I/UpdateIcingCorporaServi( 1101): UpdateCorporaTask done [took 141 ms] updated apps [took 141 ms] 
D/BackupManagerService(  455): Received broadcast Intent { act=android.intent.action.PACKAGE_ADDED dat=package:com.example.android.testing.espresso.BasicSample flg=0x4000010 (has extras) }
W/BackupManagerService(  455): Removing schedule queue dupe of com.example.android.testing.espresso.BasicSample
I/art     (  455): Explicit concurrent mark sweep GC freed 81278(4MB) AllocSpace objects, 17(1258KB) LOS objects, 33% free, 22MB/33MB, paused 1.943ms total 258.559ms
D/AndroidRuntime( 6235): Shutting down VM
W/ResourceType(  455): ResTable_typeSpec entry count inconsistent: given 1, previously 1426
W/Launcher.Model( 2672): Nobody to tell about the new app.  Launcher is probably loading.
W/ResourcesManager( 1003): Asset path '/system/framework/com.google.android.maps.jar' does not exist or contains no resources.
I/Icing   ( 1277): Indexing 314CC0875B3577CA58AC16521A56497F0625B02E from com.google.android.googlequicksearchbox
I/Icing   ( 1277): Indexing done 314CC0875B3577CA58AC16521A56497F0625B02E
D/AndroidRuntime( 6278): 
D/AndroidRuntime( 6278): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
D/AndroidRuntime( 6278): CheckJNI is OFF
E/memtrack( 6278): Couldn't load memtrack module (No such file or directory)
E/android.os.Debug( 6278): failed to load memtrack module: -2
D/AndroidRuntime( 6278): Calling main entry com.android.commands.pm.Pm
D/Finsky  ( 1594): [1] PackageVerificationReceiver.onReceive: Verification requested, id = 3
D/Finsky  ( 1594): [1] WorkerTask.onPreExecute: Verification Requested for id = 3, data=file:///data/local/tmp/app-debug-test-unaligned.apk flags=114 fromVerificationActivity=false
D/Finsky  ( 1594): [1] 2.onResponse: Verification id=3 response=0
D/Finsky  ( 1594): [1] PackageVerificationReceiver.onReceive: Verification requested, id = 3
D/DefContainer( 3872): Copying /data/local/tmp/app-debug-test-unaligned.apk to base.apk
D/PackageManager(  455): Renaming /data/app/vmdl365918615.tmp to /data/app/com.example.android.testing.espresso.BasicSample.test-1
I/art     (  455): DexFile_isDexOptNeeded failed to open oat file '/data/dalvik-cache/arm/data@app@com.example.android.testing.espresso.BasicSample.test-1@base.apk@classes.dex' for file location '/data/app/com.example.android.testing.espresso.BasicSample.test-1/base.apk': Failed to open oat filename for reading: No such file or directory
I/art     (  455): DexFile_isDexOptNeeded failed to open oat file '/data/app/com.example.android.testing.espresso.BasicSample.test-1/arm/base.odex' for file location '/data/app/com.example.android.testing.espresso.BasicSample.test-1/base.apk': Failed to open oat filename for reading: No such file or directory
I/PackageManager(  455): Running dexopt on: /data/app/com.example.android.testing.espresso.BasicSample.test-1/base.apk pkg=com.example.android.testing.espresso.BasicSample.test isa=arm vmSafeMode=false
I/dex2oat ( 6295): /system/bin/dex2oat --zip-fd=6 --zip-location=/data/app/com.example.android.testing.espresso.BasicSample.test-1/base.apk --oat-fd=7 --oat-location=/data/dalvik-cache/arm/data@app@com.example.android.testing.espresso.BasicSample.test-1@base.apk@classes.dex --instruction-set=arm --instruction-set-features=default --runtime-arg -Xms64m --runtime-arg -Xmx512m
D/libgps  (  455): proxy_gps_stop()
D/libgps  (  455): proxy_gps_status_cb()
D/libgps  (  455): proxy_gps_status_cb()
D/libgps  (  455): proxy_gps_release_wakelock_cb()
I/dex2oat ( 6295): dex2oat took 3.100s (threads: 4)
V/BackupManagerService(  455): restoreAtInstall pkg=com.example.android.testing.espresso.BasicSample.test token=4 restoreSet=0
V/BackupManagerService(  455): Finishing install immediately
W/Settings(  455): Setting install_non_market_apps has moved from android.provider.Settings.Global to android.provider.Settings.Secure, returning read-only value.
I/ConfigClient( 1277): received Intent { act=android.intent.action.PACKAGE_ADDED dat=package:com.example.android.testing.espresso.BasicSample.test flg=0x4000010 (has extras) }
D/Documents( 4253): Update found 7 roots in 8ms
I/InputReader(  455): Reconfiguring input devices.  changes=0x00000010
I/UpdateIcingCorporaServi( 1101): Updating corpora: APPS=com.example.android.testing.espresso.BasicSample.test, CONTACTS=MAYBE
I/ConfigFetchService( 1277): PackageReceiver: Intent { act=android.intent.action.PACKAGE_ADDED dat=package:com.example.android.testing.espresso.BasicSample.test flg=0x4000010 cmp=com.google.android.gms/.config.ConfigFetchService$PackageReceiver (has extras) }
D/BackupManagerService(  455): Received broadcast Intent { act=android.intent.action.PACKAGE_ADDED dat=package:com.example.android.testing.espresso.BasicSample.test flg=0x4000010 (has extras) }
I/UpdateIcingCorporaServi( 1101): UpdateCorporaTask done [took 27 ms] updated apps [took 27 ms] 
W/BackupManagerService(  455): Removing schedule queue dupe of com.example.android.testing.espresso.BasicSample.test
I/ConfigFetchService( 1277): onStartCommand Intent { act=android.intent.action.PACKAGE_ADDED dat=package:com.example.android.testing.espresso.BasicSample.test cmp=com.google.android.gms/.config.ConfigFetchService (has extras) }
D/PackageBroadcastService( 1277): Received broadcast action=android.intent.action.PACKAGE_ADDED and uri=com.example.android.testing.espresso.BasicSample.test
W/Launcher.Model( 2672): Nobody to tell about the new app.  Launcher is probably loading.
I/art     (  455): Explicit concurrent mark sweep GC freed 26369(1910KB) AllocSpace objects, 16(410KB) LOS objects, 33% free, 22MB/33MB, paused 1.774ms total 219.857ms
D/AndroidRuntime( 6278): Shutting down VM
D/AndroidRuntime( 6317): 
D/AndroidRuntime( 6317): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
D/AndroidRuntime( 6317): CheckJNI is OFF
E/memtrack( 6317): Couldn't load memtrack module (No such file or directory)
E/android.os.Debug( 6317): failed to load memtrack module: -2
D/AndroidRuntime( 6317): Calling main entry com.android.commands.am.Am
I/ActivityManager(  455): Force stopping com.example.android.testing.espresso.BasicSample appid=10205 user=0: start instr
I/ActivityManager(  455): Start proc com.example.android.testing.espresso.BasicSample for added application com.example.android.testing.espresso.BasicSample: pid=6331 uid=10205 gids={50205, 9997} abi=armeabi-v7a
I/art     ( 6331): Late-enabling -Xcheck:jni
I/MonitoringInstrumentation( 6331): Instrumentation Started!
I/AndroidJUnitRunner( 6331): Setting context classloader to 'dalvik.system.PathClassLoader[DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/data/app/com.example.android.testing.espresso.BasicSample.test-1/base.apk", zip file "/data/app/com.example.android.testing.espresso.BasicSample-1/base.apk"],nativeLibraryDirectories=[/vendor/lib, /system/lib]]]', Original: 'dalvik.system.PathClassLoader[DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/data/app/com.example.android.testing.espresso.BasicSample.test-1/base.apk", zip file "/data/app/com.example.android.testing.espresso.BasicSample-1/base.apk"],nativeLibraryDirectories=[/vendor/lib, /system/lib]]]'
D/InfraTrack( 6331): Tracking disabled due to lack of internet permissions
I/TestRequestBuilder( 6331): Scanning classpath to find tests in apks [/data/app/com.example.android.testing.espresso.BasicSample.test-1/base.apk]
I/TestRunner( 6331): run started: 2 tests
I/TestRunner( 6331): started: testChangeText_newActivity(com.example.android.testing.espresso.BasicSample.ChangeTextBehaviorTest)
I/MonitoringInstrumentation( 6331): Activities that are still in CREATED to PAUSED: 0
I/ActivityManager(  455): START u0 {act=android.intent.action.MAIN flg=0x14000000 cmp=com.example.android.testing.espresso.BasicSample/.MainActivity} from uid 10205 on display 0
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@3b34b917 in: PRE_ON_CREATE
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@3b34b917 in: CREATED
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@3b34b917 in: STARTED
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@3b34b917 in: RESUMED
D/OpenGLRenderer( 6331): Render dirty regions requested: false
D/Atlas   ( 6331): Validating map...
D/libEGL  ( 6331): loaded /system/lib/egl/libEGL_tegra.so
D/libEGL  ( 6331): loaded /system/lib/egl/libGLESv1_CM_tegra.so
D/libEGL  ( 6331): loaded /system/lib/egl/libGLESv2_tegra.so
I/OpenGLRenderer( 6331): Initialized EGL, version 1.4
D/OpenGLRenderer( 6331): Enabling debug mode 0
I/ActivityManager(  455): Displayed com.example.android.testing.espresso.BasicSample/.MainActivity: +635ms
I/LatinIME(  743): Starting input. Cursor position = -1,-1
E/RichInputConnection(  743): Unable to connect to the editor to retrieve text.
D/RichInputConnection(  743): Will try to retrieve text later.
I/InputAttributes(  743): InputType.TYPE_NULL is specified
D/InputManagerEventInjectionStrategy( 6331): Creating injection strategy with input manager.
I/LatinIME(  743): Starting input. Cursor position = 0,0
I/ViewInteraction( 6331): Performing 'type text(Espresso)' action on view with id: com.example.android.testing.espresso.BasicSample:id/editTextUserInput
D/UiControllerImpl( 6331): Injecting string: "Espresso"
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (\C0\80) with key code (59) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (E) with key code (33) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (E) with key code (33) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (\C0\80) with key code (59) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (p) with key code (44) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (p) with key code (44) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (r) with key code (46) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (r) with key code (46) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (e) with key code (33) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (e) with key code (33) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (o) with key code (43) downtime: (1932792)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (o) with key code (43) downtime: (1932792)
I/ViewInteraction( 6331): Performing 'close keyboard' action on view with id: com.example.android.testing.espresso.BasicSample:id/editTextUserInput
I/ViewInteraction( 6331): Performing 'single click' action on view with id: com.example.android.testing.espresso.BasicSample:id/activityChangeTextBtn
E/ViewAssertions( 6331): 'with text: is "Espresso"' check could not be performed because view 'with id: com.example.android.testing.espresso.BasicSample:id/show_text_view' was not found.
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@3b34b917 in: PAUSED
I/MicrophoneInputStream( 1101): mic_close gfk@308920bf
I/HotwordRecognitionRnr( 1101): Stopping hotword detection.
W/SurfaceFlinger(  129): couldn't log to binary event log: overflow.
W/IInputConnectionWrapper( 6331): showStatusIcon on inactive InputConnection
I/HotwordRecognitionRnr( 1101): Hotword detection finished
I/art     ( 6331): Explicit concurrent mark sweep GC freed 24929(1323KB) AllocSpace objects, 1(12KB) LOS objects, 40% free, 7MB/12MB, paused 1.687ms total 101.106ms
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@3b34b917 in: STOPPED
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@3b34b917 in: DESTROYED
W/LocationOracleImpl( 1101): Best location was null
W/LocationOracleImpl( 1101): Best location was null
I/art     ( 6331): Explicit concurrent mark sweep GC freed 396(18KB) AllocSpace objects, 0(0B) LOS objects, 39% free, 7MB/11MB, paused 2.870ms total 74.433ms
I/TestRunner( 6331): failed: testChangeText_newActivity(com.example.android.testing.espresso.BasicSample.ChangeTextBehaviorTest)
I/TestRunner( 6331): ----- begin exception -----
I/TestRunner( 6331): android.support.test.espresso.NoMatchingViewException: No views in hierarchy found matching: with id: com.example.android.testing.espresso.BasicSample:id/show_text_view
I/TestRunner( 6331): 
I/TestRunner( 6331): View Hierarchy:
I/TestRunner( 6331): +>DecorView{id=-1, visibility=VISIBLE, width=555, height=520, has-focus=true, has-focusable=true, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1} 
I/TestRunner( 6331): |
I/TestRunner( 6331): +->FrameLayout{id=-1, visibility=VISIBLE, width=513, height=478, has-focus=true, has-focusable=true, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=21.0, y=21.0, child-count=2} 
I/TestRunner( 6331): |
I/TestRunner( 6331): +-->FrameLayout{id=16908290, res-name=content, visibility=VISIBLE, width=513, height=478, has-focus=true, has-focusable=true, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1} 
I/TestRunner( 6331): |
I/TestRunner( 6331): +--->LinearLayout{id=-1, visibility=VISIBLE, width=513, height=478, has-focus=true, has-focusable=true, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=4} 
I/TestRunner( 6331): |
I/TestRunner( 6331): +---->TextView{id=2131165184, res-name=textToBeChanged, visibility=VISIBLE, width=119, height=39, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=197.0, y=128.0, text=Espresso, input-type=0, ime-target=false, has-links=false} 
I/TestRunner( 6331): |
I/TestRunner( 6331): +---->EditText{id=2131165185, res-name=editTextUserInput, visibility=VISIBLE, width=343, height=55, has-focus=true, has-focusable=true, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=true, is-focusable=true, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=true, editor-info=[inputType=0x20001 imeOptions=0x40000006 privateImeOptions=null actionLabel=null actionId=0 initialSelStart=8 initialSelEnd=8 initialCapsMode=0x0 hintText=type something… label=null packageName=null fieldId=0 fieldName=null extras=null ], x=85.0, y=210.0, text=Espresso, hint=type something…, input-type=131073, ime-target=true, has-links=false} 
I/TestRunner( 6331): |
I/TestRunner( 6331): +---->Button{id=2131165186, res-name=changeTextBt, visibility=VISIBLE, width=158, height=64, has-focus=false, has-focusable=true, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=false, is-focusable=true, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=177.0, y=265.0, text=Change text, input-type=0, ime-target=false, has-links=false} 
I/TestRunner( 6331): |
I/TestRunner( 6331): +---->Button{id=2131165187, res-name=activityChangeTextBtn, visibility=VISIBLE, width=343, height=64, has-focus=false, has-focusable=true, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=false, is-focusable=true, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=85.0, y=329.0, text=Open activity and change text, input-type=0, ime-target=false, has-links=false} 
I/TestRunner( 6331): |
I/TestRunner( 6331): +-->ViewStub{id=16909166, visibility=GONE, width=0, height=0, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=true, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0} 
I/TestRunner( 6331): |
I/TestRunner( 6331):    at dalvik.system.VMStack.getThreadStackTrace(Native Method)
I/TestRunner( 6331):    at java.lang.Thread.getStackTrace(Thread.java:580)
I/TestRunner( 6331):    at android.support.test.espresso.base.DefaultFailureHandler.getUserFriendlyE
I/TestRunner( 6331): ----- end exception -----
I/TestRunner( 6331): finished: testChangeText_newActivity(com.example.android.testing.espresso.BasicSample.ChangeTextBehaviorTest)
I/MicrophoneInputStream( 1101): mic_starting gfk@110891bb
I/MonitoringInstrumentation( 6331): Activities that are still in CREATED to PAUSED: 0
I/TestRunner( 6331): started: testChangeText_sameActivity(com.example.android.testing.espresso.BasicSample.ChangeTextBehaviorTest)
I/MonitoringInstrumentation( 6331): Activities that are still in CREATED to PAUSED: 0
I/AudioFlinger(  135): AudioFlinger's thread 0x40fd0008 ready to run
I/HotwordRecognitionRnr( 1101): Starting hotword detection.
I/MicrophoneInputStream( 1101): mic_started gfk@110891bb
I/ActivityManager(  455): START u0 {act=android.intent.action.MAIN flg=0x10000000 cmp=com.example.android.testing.espresso.BasicSample/.MainActivity} from uid 10205 on display 0
W/GCoreFlp( 1323): No location to return for getLastLocation()
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@143fb3f4 in: PRE_ON_CREATE
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@143fb3f4 in: CREATED
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@143fb3f4 in: STARTED
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@143fb3f4 in: RESUMED
V/ConfigFetchTask( 1277): ConfigFetchTask getDeviceDataVersionInfo(): ABFEt1WJ34I-y1RzmXeJwYm3-zibuATjSGAHNX884SH5BYO85tS6pFdHXjFPo8W_b4RdZY7G3FDKuViiPIv5LrvgrSysAbhxt_iMC-tmZrVrhRpsdQy-G2sIga9eK3lC8kfCqzI4WqOjhOMYeOIAGR37otjFeh29iv-p4lL3gzRpcK4VBi9yEH1Ip7HYPYRY06GMSPtWuNcC94ndLklgoOr4QH0JpEBLpOz97FjcpUww0krOCUm4Ru06sVO20CGycFDo24-mVUdXEx4L0IveCdfsUDOB73inl3OzMhWN316ruz8SGd_tQpI
I/HotwordWorker( 1101): onReady
I/GoogleHttpClient( 1277): Falling back to old SSLCertificateSocketFactory
I/ActivityManager(  455): Displayed com.example.android.testing.espresso.BasicSample/.MainActivity: +117ms
I/LatinIME(  743): Starting input. Cursor position = 0,0
I/ViewInteraction( 6331): Performing 'type text(Espresso)' action on view with id: com.example.android.testing.espresso.BasicSample:id/editTextUserInput
D/UiControllerImpl( 6331): Injecting string: "Espresso"
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (\C0\80) with key code (59) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (E) with key code (33) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (E) with key code (33) downtime: (1934206)
I/ConfigFetchService( 1277): launchTask
V/ConfigFetchTask( 1277): ConfigFetchTask getDeviceDataVersionInfo(): ABFEt1WJ34I-y1RzmXeJwYm3-zibuATjSGAHNX884SH5BYO85tS6pFdHXjFPo8W_b4RdZY7G3FDKuViiPIv5LrvgrSysAbhxt_iMC-tmZrVrhRpsdQy-G2sIga9eK3lC8kfCqzI4WqOjhOMYeOIAGR37otjFeh29iv-p4lL3gzRpcK4VBi9yEH1Ip7HYPYRY06GMSPtWuNcC94ndLklgoOr4QH0JpEBLpOz97FjcpUww0krOCUm4Ru06sVO20CGycFDo24-mVUdXEx4L0IveCdfsUDOB73inl3OzMhWN316ruz8SGd_tQpI
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (\C0\80) with key code (59) downtime: (1934206)
I/GoogleHttpClient( 1277): Falling back to old SSLCertificateSocketFactory
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (p) with key code (44) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (p) with key code (44) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (r) with key code (46) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (r) with key code (46) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (e) with key code (33) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (e) with key code (33) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (s) with key code (47) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (o) with key code (43) downtime: (1934206)
V/ESP_TRACE( 6331): EventInjector:Injecting event for character (o) with key code (43) downtime: (1934206)
I/ViewInteraction( 6331): Performing 'close keyboard' action on view with id: com.example.android.testing.espresso.BasicSample:id/editTextUserInput
I/ViewInteraction( 6331): Performing 'single click' action on view with id: com.example.android.testing.espresso.BasicSample:id/changeTextBt
W/InputDispatcher(  455): Permission denied: injecting event from pid 6331 uid 10205 to window Window{3b197ccc u0 InputMethod} owned by uid 10054
W/InputManager(  455): Input event injection from pid 6331 permission denied.
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@143fb3f4 in: PAUSED
I/ConfigFetchService( 1277): fetch service done; releasing wakelock
I/ConfigFetchService( 1277): stopping self
I/ConfigService(  902): onDestroy
I/art     ( 6331): Explicit concurrent mark sweep GC freed 5078(364KB) AllocSpace objects, 6(90KB) LOS objects, 40% free, 7MB/12MB, paused 3.054ms total 70.134ms
W/SurfaceFlinger(  129): couldn't log to binary event log: overflow.
W/IInputConnectionWrapper( 6331): showStatusIcon on inactive InputConnection
I/art     ( 6331): Explicit concurrent mark sweep GC freed 217(9KB) AllocSpace objects, 0(0B) LOS objects, 39% free, 7MB/12MB, paused 2.507ms total 66.390ms
I/TestRunner( 6331): failed: testChangeText_sameActivity(com.example.android.testing.espresso.BasicSample.ChangeTextBehaviorTest)
I/TestRunner( 6331): ----- begin exception -----
I/TestRunner( 6331): android.support.test.espresso.PerformException: Error performing 'single click' on view 'with id: com.example.android.testing.espresso.BasicSample:id/changeTextBt'.
I/TestRunner( 6331):    at android.support.test.espresso.PerformException$Builder.build(PerformException.java:83)
I/TestRunner( 6331):    at android.support.test.espresso.base.DefaultFailureHandler.getUserFriendlyError(DefaultFailureHandler.java:70)
I/TestRunner( 6331):    at android.support.test.espresso.base.DefaultFailureHandler.handle(DefaultFailureHandler.java:53)
I/TestRunner( 6331):    at android.support.test.espresso.ViewInteraction.runSynchronouslyOnUiThread(ViewInteraction.java:185)
I/TestRunner( 6331):    at android.support.test.espresso.ViewInteraction.doPerform(ViewInteraction.java:115)
I/TestRunner( 6331):    at android.support.test.espresso.ViewInteraction.perform(ViewInteraction.java:87)
I/TestRunner( 6331):    at com.example.android.testing.espresso.BasicSample.ChangeTextBehaviorTest.testChangeText_sameActivity(ChangeTextBehaviorTest.java:61)
I/TestRunner( 6331):    at java.lang.reflect.Method.invoke(Native Method)
I/TestRunner( 6331):    at java.lang.reflect.Method.invoke(Method.java:372)
I/TestRunner( 6331):    at android.test.InstrumentationTestCase.runMethod(InstrumentationTestCase.java:214)
I/TestRunner( 6331):    at android.test.InstrumentationTestCase.runTest(InstrumentationTestCase.java:199)
I/TestRunner( 6331):    at android.test.ActivityInstrumentationTestCase2.runTest(ActivityInstrumentationTestCase2.java:192)
I/TestRunner( 6331):    at junit.framework.TestCase.runBare(TestCase.java:134)
I/TestRunner( 6331):    at junit.framework.TestResult$1.protect(TestResult.java:115)
I/TestRunner( 6331):    at junit.framework.TestResult.runProtected(TestResult.java:133)
I/TestRunner( 6331):    at android.support.test.internal.runner.junit3.DelegatingTestResult.runProtected(DelegatingTestResult.java:90)
I/TestRunner( 6331):    at junit.framework.TestResult.run(TestResult.java:118)
I/TestRunner( 6331):    at android.support.test.internal.runner.junit3.AndroidTestResult.run(AndroidTestResult.java:49)
I/TestRunner( 6331):    at junit.framework.TestCase.run(TestCase.java:124)
I/TestRunner( 6331):    at android.support.test.internal.runner.junit3.NonLeakyTestSuite$NonLeakyTest.run(NonLeakyTestSuite.java:63)
I/TestRunner( 6331):    at junit.framework.TestSuite.runTest(TestSuite.java:243)
I/TestRunner( 6331):    at junit.framework.TestSuite.run(TestSuite.java:238)
I/TestRunner( 6331):    at android.support.test.internal.runner.junit3.DelegatingTestSuite.run(DelegatingTestSuite.java:103)
I/TestRunner( 6331):    at android.support.test.internal.runner.junit3.AndroidTestSuite.run(AndroidTestSuite.java:63)
I/TestRunner( 6331):    at android.support.test.internal.runner.junit3.JUnit38ClassRunner.run(JUnit38ClassRunner.java:90)
I/TestRunner( 6331):    at org.junit.runners.Suite.runChild(Suite.java:128)
I/TestRunner( 6331):    at org.junit.runners.Suite.runChild(Suite.java:24)
I/TestRunner( 6331):    at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
I/TestRunner( 6331):    at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
I/TestRunner( 6331):    at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
I/TestRunner( 6331):    at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
I/TestRunner( 6331):    at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:222)
I/TestRunner( 6331):    at org.junit.runners.ParentRunner.run(ParentRunner.java:300)
I/TestRunner( 6331):    at org.junit.runner.JUnitCore.run(JUnitCore.java:157)
I/TestRunner( 6331):    at org.junit.runner.JUnitCore.run(JUnitCore.java:136)
I/TestRunner( 6331):    at android.support.test.runner.AndroidJUnitRunner.onStart(AndroidJUnitRunner.java:270)
I/TestRunner( 6331):    at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1837)
I/TestRunner( 6331): Caused by: android.support.test.espresso.PerformException: Error performing 'Send down montion event' on view 'unknown'.
I/TestRunner( 6331):    at android.support.test.espresso.PerformException$Builder.build(PerformException.java:83)
I/TestRunner( 6331):    at android.support.test.espresso.action.MotionEvents.sendDown(MotionEvents.java:104)
I/TestRunner( 6331):    at android.support.test.espresso.action.Tap.sendSingleTap(Tap.java:133)
I/TestRunner( 6331):    at android.support.test.espresso.action.Tap.access$100(Tap.java:35)
I/TestRunner( 6331):    at android.support.test.espresso.action.Tap$1.sendTap(Tap.java:40)
I/TestRunner( 6331):    at android.support.test.espresso.action.GeneralClickAction.perform(GeneralClickAction.java:98)
I/TestRunner( 6331):    at android.support.test.espresso.ViewInteraction$1.run(ViewInteraction.java:144)
I/TestRunner( 6331):    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:422)
I/TestRunner( 6331):    at java.util.concurrent.FutureTask.run(FutureTask.java:237)
I/TestRunner( 6331):    at android.os.Handler.handleCallback(Handler.java:739)
I/TestRunner( 6331):    at android.os.Handler.dispatchMessage(Handler.java:95)
I/TestRunner( 6331):    at android.os.Looper.loop(Looper.java:135)
I/TestRunner( 6331):    at android.app.ActivityThre
I/TestRunner( 6331): ----- end exception -----
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@143fb3f4 in: STOPPED
D/LifecycleMonitor( 6331): Lifecycle status change: com.example.android.testing.espresso.BasicSample.MainActivity@143fb3f4 in: DESTROYED
I/TestRunner( 6331): finished: testChangeText_sameActivity(com.example.android.testing.espresso.BasicSample.ChangeTextBehaviorTest)
W/LocationOracleImpl( 1101): Best location was null
I/MonitoringInstrumentation( 6331): Activities that are still in CREATED to PAUSED: 0
I/TestRunner( 6331): run finished: 2 tests, 2 failed, 0 ignored
I/MonitoringInstrumentation( 6331): Activities that are still in CREATED to PAUSED: 0
I/MonitoringInstrumentation( 6331): waitForActivitiesToComplete() took: 0ms
D/AndroidRuntime( 6317): Shutting down VM
I/ActivityManager(  455): Force stopping com.example.android.testing.espresso.BasicSample appid=10205 user=0: finished inst
I/ActivityManager(  455): Killing 6331:com.example.android.testing.espresso.BasicSample/u0a205 (adj 0): stop com.example.android.testing.espresso.BasicSample
W/ActivityManager(  455): Spurious death for ProcessRecord{132139fe 6331:com.example.android.testing.espresso.BasicSample/u0a205}, curProc for 6331: null
D/AndroidRuntime( 6391): 
D/AndroidRuntime( 6391): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
D/AndroidRuntime( 6391): CheckJNI is OFF
E/memtrack( 6391): Couldn't load memtrack module (No such file or directory)
E/android.os.Debug( 6391): failed to load memtrack module: -2
D/AndroidRuntime( 6391): Calling main entry com.android.commands.pm.Pm
I/ActivityManager(  455): Force stopping com.example.android.testing.espresso.BasicSample.test appid=10206 user=-1: uninstall pkg
I/ActivityManager(  455): Force stopping com.example.android.testing.espresso.BasicSample.test appid=10206 user=0: pkg removed
W/GeofencerStateMachine( 1323): Ignoring removeGeofence because network location is disabled.
I/InputReader(  455): Reconfiguring input devices.  changes=0x00000010
D/Documents( 4253): Update found 7 roots in 8ms
D/VoicemailCleanupService( 1076): Cleaning up data for package: com.example.android.testing.espresso.BasicSample.test
I/UpdateIcingCorporaServi( 1101): Updating corpora: APPS=com.example.android.testing.espresso.BasicSample.test, CONTACTS=MAYBE
I/LatinIME:LogUtils(  743): Dictionary info: dictionary = main:en_us ; version = 52 ; date = 1412572954
I/LatinIME:LogUtils(  743): Dictionary info: dictionary = main:en_us ; version = 52 ; date = 1412572954
W/Launcher( 1003): setApplicationContext called twice! old=com.google.android.velvet.VelvetApplication@3b34b917 new=com.google.android.velvet.VelvetApplication@3b34b917
W/ContextImpl( 3915): Calling a method in the system process without a qualified user: android.app.ContextImpl.startService:1686 android.content.ContextWrapper.startService:515 android.content.ContextWrapper.startService:515 com.android.keychain.KeyChainBroadcastReceiver.onReceive:12 android.app.ActivityThread.handleReceiver:2579 
I/UpdateIcingCorporaServi( 1101): UpdateCorporaTask done [took 50 ms] updated apps [took 50 ms] 
I/ConfigFetchService( 1277): PackageReceiver: Intent { act=android.intent.action.PACKAGE_REMOVED dat=package:com.example.android.testing.espresso.BasicSample.test flg=0x4000010 cmp=com.google.android.gms/.config.ConfigFetchService$PackageReceiver (has extras) }
I/ConfigService(  902): onCreate
I/ConfigService(  902): onBind for Intent { act=com.google.android.gms.config.UPDATE pkg=com.google.android.gms } action com.google.android.gms.config.UPDATE
I/ConfigFetchService( 1277): onStartCommand Intent { act=android.intent.action.PACKAGE_REMOVED dat=package:com.example.android.testing.espresso.BasicSample.test cmp=com.google.android.gms/.config.ConfigFetchService (has extras) }
I/ConfigService(  902): onBind returning update interface
I/ConfigService(  902): onBind for Intent { act=com.google.android.gms.config.START pkg=com.google.android.gms } action com.google.android.gms.config.START
I/ConfigService(  902): onBind returning config service
I/ConfigService(  902): onDestroy
I/LocationSettingsChecker( 3937): Removing dialog suppression flag for package com.example.android.testing.espresso.BasicSample.test
D/PackageBroadcastService( 1277): Received broadcast action=android.intent.action.PACKAGE_REMOVED and uri=com.example.android.testing.espresso.BasicSample.test
D/AccountUtils( 1277): Clearing selected account for com.example.android.testing.espresso.BasicSample.test
I/Icing   ( 1277): doRemovePackageData com.example.android.testing.espresso.BasicSample.test
D/BackupManagerService(  455): Received broadcast Intent { act=android.intent.action.PACKAGE_REMOVED dat=package:com.example.android.testing.espresso.BasicSample.test flg=0x4000010 (has extras) }
D/JobSchedulerService(  455): Receieved: android.intent.action.PACKAGE_REMOVED
I/art     (  455): Explicit concurrent mark sweep GC freed 32692(1909KB) AllocSpace objects, 8(2MB) LOS objects, 33% free, 23MB/35MB, paused 2.161ms total 286.431ms
D/AndroidRuntime( 6391): Shutting down VM
W/ResourceType(  455): ResTable_typeSpec entry count inconsistent: given 1, previously 1426
W/Launcher.Model( 2672): Nobody to tell about the new app.  Launcher is probably loading.
D/AndroidRuntime( 6427): 
D/AndroidRuntime( 6427): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
D/AndroidRuntime( 6427): CheckJNI is OFF
E/memtrack( 6427): Couldn't load memtrack module (No such file or directory)
E/android.os.Debug( 6427): failed to load memtrack module: -2
D/AndroidRuntime( 6427): Calling main entry com.android.commands.pm.Pm
I/ActivityManager(  455): Force stopping com.example.android.testing.espresso.BasicSample appid=10205 user=-1: uninstall pkg
I/ActivityManager(  455): Force stopping com.example.android.testing.espresso.BasicSample appid=10205 user=0: pkg removed
I/InputReader(  455): Reconfiguring input devices.  changes=0x00000010
W/GeofencerStateMachine( 1323): Ignoring removeGeofence because network location is disabled.
I/art     ( 2672): Explicit concurrent mark sweep GC freed 327(16KB) AllocSpace objects, 1(36KB) LOS objects, 24% free, 5MB/7MB, paused 523us total 40.393ms
D/VoicemailCleanupService( 1076): Cleaning up data for package: com.example.android.testing.espresso.BasicSample
I/LatinIME:LogUtils(  743): Dictionary info: dictionary = main:en_us ; version = 52 ; date = 1412572954
D/Documents( 4253): Update found 7 roots in 44ms
I/art     ( 1101): Explicit concurrent mark sweep GC freed 21495(1438KB) AllocSpace objects, 7(795KB) LOS objects, 39% free, 11MB/19MB, paused 2.336ms total 67.331ms
I/LatinIME:LogUtils(  743): Dictionary info: dictionary = main:en_us ; version = 52 ; date = 1412572954
D/BackupManagerService(  455): Received broadcast Intent { act=android.intent.action.PACKAGE_REMOVED dat=package:com.example.android.testing.espresso.BasicSample flg=0x4000010 (has extras) }
D/JobSchedulerService(  455): Receieved: android.intent.action.PACKAGE_REMOVED
I/art     ( 1003): Explicit concurrent mark sweep GC freed 75708(3MB) AllocSpace objects, 5(180KB) LOS objects, 39% free, 15MB/25MB, paused 1.702ms total 114.393ms
D/TaskPersister(  455): removeObsoleteFile: deleting file=377_task.xml
D/TaskPersister(  455): removeObsoleteFile: deleting file=377_task_thumbnail.png
I/UpdateIcingCorporaServi( 1101): Updating corpora: APPS=com.example.android.testing.espresso.BasicSample, CONTACTS=MAYBE
W/Launcher( 1003): setApplicationContext called twice! old=com.google.android.velvet.VelvetApplication@3b34b917 new=com.google.android.velvet.VelvetApplication@3b34b917
W/ContextImpl( 3915): Calling a method in the system process without a qualified user: android.app.ContextImpl.startService:1686 android.content.ContextWrapper.startService:515 android.content.ContextWrapper.startService:515 com.android.keychain.KeyChainBroadcastReceiver.onReceive:12 android.app.ActivityThread.handleReceiver:2579 
I/ConfigFetchService( 1277): PackageReceiver: Intent { act=android.intent.action.PACKAGE_REMOVED dat=package:com.example.android.testing.espresso.BasicSample flg=0x4000010 cmp=com.google.android.gms/.config.ConfigFetchService$PackageReceiver (has extras) }
I/ConfigService(  902): onCreate
I/ConfigService(  902): onBind for Intent { act=com.google.android.gms.config.UPDATE pkg=com.google.android.gms } action com.google.android.gms.config.UPDATE
I/ConfigFetchService( 1277): onStartCommand Intent { act=android.intent.action.PACKAGE_REMOVED dat=package:com.example.android.testing.espresso.BasicSample cmp=com.google.android.gms/.config.ConfigFetchService (has extras) }
I/ConfigService(  902): onBind returning update interface
I/ConfigService(  902): onBind for Intent { act=com.google.android.gms.config.START pkg=com.google.android.gms } action com.google.android.gms.config.START
I/ConfigService(  902): onBind returning config service
W/Launcher.Model( 2672): Nobody to tell about the new app.  Launcher is probably loading.
I/ConfigService(  902): onDestroy
I/LocationSettingsChecker( 3937): Removing dialog suppression flag for package com.example.android.testing.espresso.BasicSample
D/PackageBroadcastService( 1277): Received broadcast action=android.intent.action.PACKAGE_REMOVED and uri=com.example.android.testing.espresso.BasicSample
D/AccountUtils( 1277): Clearing selected account for com.example.android.testing.espresso.BasicSample
W/ResourcesManager( 1003): Asset path '/system/framework/com.google.android.maps.jar' does not exist or contains no resources.
I/UpdateIcingCorporaServi( 1101): UpdateCorporaTask done [took 181 ms] updated apps [took 181 ms] 
I/Icing   ( 1277): doRemovePackageData com.example.android.testing.espresso.BasicSample
I/art     (  455): Explicit concurrent mark sweep GC freed 21999(1520KB) AllocSpace objects, 5(960KB) LOS objects, 33% free, 22MB/33MB, paused 3.016ms total 314.013ms
D/AndroidRuntime( 6427): Shutting down VM

The soft keyboard is still overlapping the buttons when are clicked. http://stackoverflow.com/questions/3553779/android-dismiss-keyboard/18858246#18858246

Related code:

  private void tryToCloseKeyboard(View view, UiController uiController) throws TimeoutException {
    InputMethodManager imm = (InputMethodManager) getRootActivity(uiController)
        .getSystemService(Context.INPUT_METHOD_SERVICE);
    final AtomicInteger atomicResultCode = new AtomicInteger();
    final CountDownLatch latch = new CountDownLatch(1);

    ResultReceiver result = new ResultReceiver(null) {
      @Override
      protected void onReceiveResult(int resultCode, Bundle resultData) {
        atomicResultCode.set(resultCode);
        latch.countDown();
      }
    };

    if (!imm.hideSoftInputFromWindow(view.getWindowToken(), 0, result)) {
      Log.w(TAG, "Attempting to close soft keyboard, while it is not shown.");
      return;
    }

    try {
      if (!latch.await(2, TimeUnit.SECONDS)) {
        throw new TimeoutException("Wait on operation result timed out.");
      }
    } catch (InterruptedException e) {
      throw new PerformException.Builder()
        .withActionDescription(this.getDescription())
        .withViewDescription(HumanReadables.describe(view))
        .withCause(new RuntimeException("Waiting for soft keyboard close result was interrupted."))
        .build();
    }

You could use the result to check it or gain time

Request to hide the soft input window from the context of the window that is currently accepting input. This should be called as a result of the user doing some actually than fairly explicitly requests to have the input window hidden.
Parameters:
windowToken The token of the window that is making the request, as returned by View.getWindowToken().
flags Provides additional operating flags. Currently may be 0 or have the HIDE_IMPLICIT_ONLY bit set.
resultReceiver If non-null, this will be called by the IME when it has processed your request to tell you what it has done. The result code you receive may be either RESULT_UNCHANGED_SHOWN, RESULT_UNCHANGED_HIDDEN, RESULT_SHOWN, or RESULT_HIDDEN.
803 
804     public boolean More ...hideSoftInputFromWindow(IBinder windowToken, int flags,
805             ResultReceiver resultReceiver) {
806         checkFocus();
807         synchronized (mH) {
808             if (mServedView == null || mServedView.getWindowToken() != windowToken) {
809                 return false;
810             }
811 
812             try {
813                 return mService.hideSoftInput(mClient, flags, resultReceiver);
814             } catch (RemoteException e) {
815             }
816             return false;
817         }
818     }

Issue Analytics

  • State:closed
  • Created 9 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

8reactions
another-davecommented, Dec 3, 2019

I know this is really dragging up a zombie thread, but I’m hitting the same issue now with androidx.test.espresso:espresso-core:3.2.0 testing on Android 10 emulator.

It’s an intermittent failure only (occurring on CI) leading to:

androidx.test.espresso.PerformException: Error performing 'single click' on view 'with string from resource id [X]

Screenshots on failure can show me the soft keyboard still open blocking the button trying to be clicked.

Does anyone have any idea what the workaround mentioned above is/was?

Tried to track it down, but the link about goes to a page “android-test-kit has Moved!” — which gives a link to google.github.io/android-testing-support-library, which then gives a 404.

Old Google Groups which mentioned the issue seem to have been taking offline too.

0reactions
piotrek1543commented, Nov 4, 2015

Thanks @ardock

Read more comments on GitHub >

github_iconTop Results From Across the Web

Issue: ViewAction closeSoftKeyboard() does ensure that soft ...
Tests always fail on real devices: Nexus7 (2012), Android 5.0.2, factory image, landscape. (Google keyboard, animations disabled)
Read more >
I can't make ViewActions.closeSoftKeyboard() work in ...
closeSoftKeyboard ();. Test runs successfully, but fails after typing some text in EditText in my layout. And keyboard is still there, showing.
Read more >
Espresso | Android Developers
Test authors can initiate testing by using one of the on* methods (e.g. onView) ... Closes soft keyboard if open. ... public static...
Read more >
espresso/core/src/main/java/android/support/test ... - Google Git
* Closes soft keyboard if open. */. public static void closeSoftKeyboard() ...
Read more >
Source Code for Espresso.java - AndroidX Tech
ViewActions.click; import static androidx.test.espresso.action. ... ViewInteraction object - it does not interact with the application * under test at all.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found