Skip to content

Make all UI tests pass and add a few more tests #2700

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Mar 23, 2019

Conversation

maskaravivek
Copy link
Member

@maskaravivek maskaravivek commented Mar 21, 2019

Some tests were failing when the whole test suite was run. This PR addresses that issue.

Also, I have added a couple of other UI tests.

@maskaravivek maskaravivek requested a review from domdomegg March 21, 2019 15:23
@codecov-io
Copy link

codecov-io commented Mar 21, 2019

Codecov Report

Merging #2700 into master will decrease coverage by <.01%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##           master   #2700      +/-   ##
=========================================
- Coverage    2.72%   2.72%   -0.01%     
=========================================
  Files         267     267              
  Lines       12814   12815       +1     
  Branches     1140    1140              
=========================================
  Hits          349     349              
- Misses      12439   12440       +1     
  Partials       26      26
Impacted Files Coverage Δ
...mons/explore/recentsearches/RecentSearchesDao.java 0% <0%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 239f749...9e3a6c4. Read the comment docs.

Copy link
Member

@domdomegg domdomegg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

testAchievements always fails as it does not give time for login - also having a look at the test it doesn't really test the achievements, just really navigating to achievements. Maybe a better way would be somehow setting a username for test by injecting/mocking something - we could remove for now? Ideally we can do this in as many places as possible - the only place we actually need to login as part of another test is upload and notifications as we need to be properly authenticated to get the data.

Also, I think we should merge LoginActivityTest and LoginTest given how close they are. I understand they are different - one tests the features in the activity and the other tests the login but as they are so closely related I think they may as well be combined as I think people searching for tests will go to both and not know immediately which one they want.

Lastly, UITestHelper.loginUser should call Espresso.closeSoftKeyboard() after entering the password. This is because on some devices the keyboard covers the login button which causes an exception in Espresso as it is not visible.

@maskaravivek
Copy link
Member Author

testAchievements always fails as it does not give time for login

It works locally for me every time.

Maybe a better way would be somehow setting a username for test by injecting/mocking something > - we could remove for now?

Yes, mocking might be better. I wanted to add a basic test, for now, to ensure the activity opens and doesn't crash. We can probably enhance it later.

Also, I think we should merge LoginActivityTest and LoginTest given how close they are.

The issue is that I tried fixing the order of test execution but it doesnt work for me. If login test runs first, then the forgot password test fails because the app resumes from main activity. I thought it might be easier to just separate out the classes.

Lastly, UITestHelper.loginUser should call Espresso.closeSoftKeyboard() after entering the password.

Done

@domdomegg
Copy link
Member

domdomegg commented Mar 21, 2019

testAchievements always fails as it does not give time for login

It works locally for me every time.

Test clearing the app data and then running the test

Lastly, UITestHelper.loginUser should call Espresso.closeSoftKeyboard() after entering the password.

Done

I don't think you've pushed these changes to your uiTests branch


Otherwise everything else makes sense

@maskaravivek
Copy link
Member Author

Test clearing the app data and then running the test

I am already clearing the data in @After but somehow the 2nd test in the same class starts the app from background.

@domdomegg
Copy link
Member

In case it helps, this is a GIF of testAchievements failing for me:

issue

And here are the logs:

androidx.test.espresso.NoMatchingViewException: No views in hierarchy found matching: with id: fr.free.nrw.commons.beta:id/drawer_layout

View Hierarchy:
+>DecorView{id=-1, visibility=VISIBLE, width=684, height=322, 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, layout-params={(0,0)(wrapxwrap) gr=CENTER sim={adjust=pan} ty=APPLICATION fmt=TRANSLUCENT wanim=0x10302f9
fl=DIM_BEHIND ALT_FOCUSABLE_IM SPLIT_TOUCH HARDWARE_ACCELERATED}, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+->FrameLayout{id=-1, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@197ea07, tag=null, root-is-layout-requested=false, has-input-connection=false, x=32.0, y=32.0, child-count=2}
|
+-->FrameLayout{id=16908290, res-name=content, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@461495d, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+--->AlertDialogLayout{id=16909162, res-name=parentPanel, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@7f83a1e, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=4}
|
+---->LinearLayout{id=16909428, res-name=topPanel, visibility=VISIBLE, width=620, height=90, 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, layout-params=android.widget.LinearLayout$LayoutParams@4d94715, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2}
|
+----->LinearLayout{id=16909418, res-name=title_template, visibility=VISIBLE, width=620, height=90, 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, layout-params=android.widget.LinearLayout$LayoutParams@a17d5b8, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2}
|
+------>AppCompatImageView{id=16908294, res-name=icon, 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, layout-params=android.widget.LinearLayout$LayoutParams@3943f91, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+------>DialogTitle{id=16908701, res-name=alertTitle, visibility=VISIBLE, width=524, height=54, 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, layout-params=android.widget.LinearLayout$LayoutParams@ca36ef6, tag=null, root-is-layout-requested=false, has-input-connection=false, x=48.0, y=36.0, text=Logging in, input-type=0, ime-target=false, has-links=false}
|
+----->Space{id=16909413, res-name=titleDividerNoCustom, 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, layout-params=android.widget.LinearLayout$LayoutParams@5a962f7, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+---->FrameLayout{id=16908813, res-name=contentPanel, 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, layout-params=android.widget.LinearLayout$LayoutParams@a2c43cd, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+----->ScrollView{id=16909256, res-name=scrollView, visibility=VISIBLE, 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, layout-params=android.widget.FrameLayout$LayoutParams@2873793, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+------>LinearLayout{id=-1, visibility=VISIBLE, 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, layout-params=android.widget.FrameLayout$LayoutParams@d63b9ef, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=3}
|
+------->Space{id=16909395, res-name=textSpacerNoTitle, 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, layout-params=android.widget.LinearLayout$LayoutParams@3f72cfc, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+------->AppCompatTextView{id=16908299, res-name=message, 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, layout-params=android.widget.LinearLayout$LayoutParams@6db1f85, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+------->Space{id=16909394, res-name=textSpacerNoButtons, visibility=VISIBLE, 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, layout-params=android.widget.LinearLayout$LayoutParams@4c521da, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+---->FrameLayout{id=16908820, res-name=customPanel, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.LinearLayout$LayoutParams@f081ce8, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=90.0, child-count=1}
|
+----->FrameLayout{id=16908331, res-name=custom, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.FrameLayout$LayoutParams@a6381a6, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+------>FrameLayout{id=-1, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.FrameLayout$LayoutParams@9b61f94, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+------->LinearLayout{id=16908751, res-name=body, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.FrameLayout$LayoutParams@f3d2b83, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2}
|
+-------->ProgressBar{id=16908301, res-name=progress, visibility=VISIBLE, width=96, height=96, 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, layout-params=android.widget.LinearLayout$LayoutParams@a9fa100, tag=null, root-is-layout-requested=false, has-input-connection=false, x=48.0, y=36.0}
|
+-------->AppCompatTextView{id=16908299, res-name=message, visibility=VISIBLE, width=380, height=38, 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, layout-params=android.widget.LinearLayout$LayoutParams@f05bd39, tag=null, root-is-layout-requested=false, has-input-connection=false, x=192.0, y=65.0, text=Please wait…, input-type=0, ime-target=false, has-links=false}
|
+---->ScrollView{id=16908766, res-name=buttonPanel, 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=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@11cfcdf, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+----->ButtonBarLayout{id=-1, visibility=VISIBLE, 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, layout-params=android.widget.FrameLayout$LayoutParams@5f09018, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=4}
|
+------>AppCompatButton{id=16908315, res-name=button3, visibility=GONE, width=0, height=0, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=false, is-focusable=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@de4da71, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+------>Space{id=16909328, res-name=spacer, visibility=INVISIBLE, 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, layout-params=android.widget.LinearLayout$LayoutParams@965a056, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+------>AppCompatButton{id=16908314, res-name=button2, visibility=GONE, width=0, height=0, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=false, is-focusable=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@fa3a8d7, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+------>AppCompatButton{id=16908313, res-name=button1, visibility=GONE, width=0, height=0, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=false, is-focusable=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@36a95c4, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+-->ViewStub{id=16908682, res-name=action_mode_bar_stub, 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, layout-params=android.widget.FrameLayout$LayoutParams@79bacad, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
at dalvik.system.VMStack.getThreadStackTrace(Native Method)
at java.lang.Thread.getStackTrace(Thread.java:1538)
at androidx.test.espresso.base.DefaultFailureHandler.getUserFriendlyError(DefaultFailureHandler.java:94)
at androidx.test.espresso.base.DefaultFailureHandler.handle(DefaultFailureHandler.java:57)
at androidx.test.espresso.ViewInteraction.waitForAndHandleInteractionResults(ViewInteraction.java:316)
at androidx.test.espresso.ViewInteraction.desugaredPerform(ViewInteraction.java:177)
at androidx.test.espresso.ViewInteraction.perform(ViewInteraction.java:118)
at fr.free.nrw.commons.AchievementsActivityTest.testAchievements(AchievementsActivityTest.kt:41)
at java.lang.reflect.Method.invoke(Native Method)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at androidx.test.internal.runner.junit4.statement.RunBefores.evaluate(RunBefores.java:80)
at androidx.test.internal.runner.junit4.statement.RunAfters.evaluate(RunAfters.java:61)
at androidx.test.rule.ActivityTestRule$ActivityStatement.evaluate(ActivityTestRule.java:531)
at org.junit.rules.RunRules.evaluate(RunRules.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at androidx.test.runner.AndroidJUnit4.run(AndroidJUnit4.java:104)
at org.junit.runners.Suite.runChild(Suite.java:128)
at org.junit.runners.Suite.runChild(Suite.java:27)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
at androidx.test.internal.runner.TestExecutor.execute(TestExecutor.java:56)
at androidx.test.runner.AndroidJUnitRunner.onStart(AndroidJUnitRunner.java:388)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:2145)

@maskaravivek
Copy link
Member Author

@domdomegg Can you share logcat as well.

@domdomegg
Copy link
Member

domdomegg commented Mar 21, 2019

Logcat
2019-03-21 20:23:25.691 21644-21644/? I/rw.commons.bet: Not late-enabling -Xcheck:jni (already on)
2019-03-21 20:23:25.709 21644-21644/? W/rw.commons.bet: Unexpected CPU variant for X86 using defaults: x86
2019-03-21 20:23:25.749 21644-21644/fr.free.nrw.commons.beta W/ActivityThread: Package uses different ABI(s) than its instrumentation: package[fr.free.nrw.commons.beta]: x86, null instrumentation[fr.free.nrw.commons.beta.test]: null, null
2019-03-21 20:23:25.751 21644-21644/fr.free.nrw.commons.beta I/rw.commons.bet: The ClassLoaderContext is a special shared library.
2019-03-21 20:23:25.752 21644-21644/fr.free.nrw.commons.beta I/chatty: uid=10085(fr.free.nrw.commons.beta) identical 1 line
2019-03-21 20:23:25.752 21644-21644/fr.free.nrw.commons.beta I/rw.commons.bet: The ClassLoaderContext is a special shared library.
2019-03-21 20:23:26.072 21644-21644/fr.free.nrw.commons.beta E/LoadedApk: Unable to instantiate appComponentFactory
    java.lang.ClassNotFoundException: Didn't find class "fr.free.nrw.commons.beta.commons" on path: DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/base.apk", zip file "/data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/base.apk"],nativeLibraryDirectories=[/data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/lib/x86, /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/lib/x86, /data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/base.apk!/lib/x86, /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/base.apk!/lib/x86, /system/lib]]
        at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:134)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
        at android.app.LoadedApk.createAppFactory(LoadedApk.java:226)
        at android.app.LoadedApk.createOrUpdateClassLoaderLocked(LoadedApk.java:731)
        at android.app.LoadedApk.getClassLoader(LoadedApk.java:810)
        at android.app.LoadedApk.getResources(LoadedApk.java:1032)
        at android.app.ContextImpl.createAppContext(ContextImpl.java:2345)
        at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5749)
        at android.app.ActivityThread.access$1100(ActivityThread.java:199)
        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1650)
        at android.os.Handler.dispatchMessage(Handler.java:106)
        at android.os.Looper.loop(Looper.java:193)
        at android.app.ActivityThread.main(ActivityThread.java:6669)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
2019-03-21 20:23:26.092 21644-21644/fr.free.nrw.commons.beta I/rw.commons.bet: The ClassLoaderContext is a special shared library.
2019-03-21 20:23:26.092 21644-21644/fr.free.nrw.commons.beta I/rw.commons.bet: The ClassLoaderContext is a special shared library.
2019-03-21 20:23:26.383 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/app/Instrumentation;->execStartActivity(Landroid/content/Context;Landroid/os/IBinder;Landroid/os/IBinder;Landroid/app/Activity;Landroid/content/Intent;ILandroid/os/Bundle;)Landroid/app/Instrumentation$ActivityResult; (light greylist, linking)
2019-03-21 20:23:26.384 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/app/Instrumentation;->execStartActivity(Landroid/content/Context;Landroid/os/IBinder;Landroid/os/IBinder;Ljava/lang/String;Landroid/content/Intent;ILandroid/os/Bundle;)Landroid/app/Instrumentation$ActivityResult; (light greylist, linking)
2019-03-21 20:23:26.413 21644-21644/fr.free.nrw.commons.beta I/MonitoringInstr: Instrumentation started!
2019-03-21 20:23:26.413 21644-21644/fr.free.nrw.commons.beta I/MonitoringInstr: Setting context classloader to 'dalvik.system.PathClassLoader[DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/base.apk", zip file "/data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/base.apk"],nativeLibraryDirectories=[/data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/lib/x86, /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/lib/x86, /data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/base.apk!/lib/x86, /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/base.apk!/lib/x86, /system/lib]]]', Original: 'dalvik.system.PathClassLoader[DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/base.apk", zip file "/data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/base.apk"],nativeLibraryDirectories=[/data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/lib/x86, /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/lib/x86, /data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/base.apk!/lib/x86, /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/base.apk!/lib/x86, /system/lib]]]'
2019-03-21 20:23:26.469 21644-21644/fr.free.nrw.commons.beta I/ACRA: Migrating unsent ACRA reports to new file locations
2019-03-21 20:23:26.469 21644-21644/fr.free.nrw.commons.beta I/ACRA: Migrated 0 unsent reports
2019-03-21 20:23:26.471 21644-21644/fr.free.nrw.commons.beta I/ACRA: Converting unsent ACRA reports to json
2019-03-21 20:23:26.471 21644-21644/fr.free.nrw.commons.beta I/ACRA: Converted 0 unsent reports
2019-03-21 20:23:26.471 21644-21644/fr.free.nrw.commons.beta I/ACRA: ACRA is enabled for fr.free.nrw.commons.beta, initializing...
2019-03-21 20:23:26.498 21644-21644/fr.free.nrw.commons.beta D/NetworkSecurityConfig: No Network Security Config specified, using platform default
2019-03-21 20:23:26.521 21644-21644/fr.free.nrw.commons.beta D/SoLoader: init start
2019-03-21 20:23:26.521 21644-21644/fr.free.nrw.commons.beta D/SoLoader: adding system library source: /vendor/lib
2019-03-21 20:23:26.521 21644-21644/fr.free.nrw.commons.beta D/SoLoader: adding system library source: /system/lib
2019-03-21 20:23:26.521 21644-21644/fr.free.nrw.commons.beta D/SoLoader: adding application source: com.facebook.soloader.DirectorySoSource[root = /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/lib/x86 flags = 0]
2019-03-21 20:23:26.522 21644-21644/fr.free.nrw.commons.beta D/SoLoader: adding backup source from : com.facebook.soloader.ApkSoSource[root = /data/data/fr.free.nrw.commons.beta/lib-main flags = 1]
2019-03-21 20:23:26.522 21644-21644/fr.free.nrw.commons.beta D/SoLoader: Preparing SO source: com.facebook.soloader.DirectorySoSource[root = /system/lib flags = 2]
2019-03-21 20:23:26.522 21644-21644/fr.free.nrw.commons.beta D/SoLoader: Preparing SO source: com.facebook.soloader.DirectorySoSource[root = /vendor/lib flags = 2]
2019-03-21 20:23:26.522 21644-21644/fr.free.nrw.commons.beta D/SoLoader: Preparing SO source: com.facebook.soloader.DirectorySoSource[root = /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/lib/x86 flags = 0]
2019-03-21 20:23:26.522 21644-21644/fr.free.nrw.commons.beta D/SoLoader: Preparing SO source: com.facebook.soloader.ApkSoSource[root = /data/data/fr.free.nrw.commons.beta/lib-main flags = 1]
2019-03-21 20:23:26.523 21644-21644/fr.free.nrw.commons.beta V/fb-UnpackingSoSource: locked dso store /data/user/0/fr.free.nrw.commons.beta/lib-main
2019-03-21 20:23:26.524 21644-21644/fr.free.nrw.commons.beta V/fb-UnpackingSoSource: deps mismatch on deps store: regenerating
2019-03-21 20:23:26.524 21644-21644/fr.free.nrw.commons.beta V/fb-UnpackingSoSource: so store dirty: regenerating
2019-03-21 20:23:26.545 21644-21644/fr.free.nrw.commons.beta D/ApkSoSource: not allowing consideration of lib/x86/libimagepipeline.so: deferring to libdir
2019-03-21 20:23:26.545 21644-21644/fr.free.nrw.commons.beta D/ApkSoSource: not allowing consideration of lib/x86/libmapbox-gl.so: deferring to libdir
2019-03-21 20:23:26.545 21644-21644/fr.free.nrw.commons.beta D/ApkSoSource: not allowing consideration of lib/x86/libnative-filters.so: deferring to libdir
2019-03-21 20:23:26.545 21644-21644/fr.free.nrw.commons.beta D/ApkSoSource: not allowing consideration of lib/x86/libnative-imagetranscoder.so: deferring to libdir
2019-03-21 20:23:26.545 21644-21644/fr.free.nrw.commons.beta V/fb-UnpackingSoSource: regenerating DSO store com.facebook.soloader.ApkSoSource
2019-03-21 20:23:26.545 21644-21644/fr.free.nrw.commons.beta V/fb-UnpackingSoSource: Finished regenerating DSO store com.facebook.soloader.ApkSoSource
2019-03-21 20:23:26.546 21644-21644/fr.free.nrw.commons.beta V/fb-UnpackingSoSource: starting syncer worker
2019-03-21 20:23:26.548 21644-21644/fr.free.nrw.commons.beta V/fb-UnpackingSoSource: releasing dso store lock for /data/user/0/fr.free.nrw.commons.beta/lib-main (from syncer thread)
2019-03-21 20:23:26.549 21644-21644/fr.free.nrw.commons.beta V/fb-UnpackingSoSource: not releasing dso store lock for /data/user/0/fr.free.nrw.commons.beta/lib-main (syncer thread started)
2019-03-21 20:23:26.549 21644-21644/fr.free.nrw.commons.beta D/SoLoader: init finish: 4 SO sources prepared
2019-03-21 20:23:26.549 21644-21644/fr.free.nrw.commons.beta D/SoLoader: init exiting
2019-03-21 20:23:26.560 21644-21673/fr.free.nrw.commons.beta I/stetho: Listening on @stetho_fr.free.nrw.commons.beta_devtools_remote
2019-03-21 20:23:26.568 21644-21644/fr.free.nrw.commons.beta I/MonitoringInstr: No JSBridge.
2019-03-21 20:23:26.568 21644-21660/fr.free.nrw.commons.beta I/MonitoringInstr: Setting context classloader to 'dalvik.system.PathClassLoader[DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/base.apk", zip file "/data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/base.apk"],nativeLibraryDirectories=[/data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/lib/x86, /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/lib/x86, /data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/base.apk!/lib/x86, /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/base.apk!/lib/x86, /system/lib]]]', Original: 'dalvik.system.PathClassLoader[DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/base.apk", zip file "/data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/base.apk"],nativeLibraryDirectories=[/data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/lib/x86, /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/lib/x86, /data/app/fr.free.nrw.commons.beta.test-e5Qba97etk2aZ_WMvD86Yg==/base.apk!/lib/x86, /data/app/fr.free.nrw.commons.beta-DY8AWuEUPsTsdBLaB6ITqw==/base.apk!/lib/x86, /system/lib]]]'
2019-03-21 20:23:26.576 21644-21660/fr.free.nrw.commons.beta I/UsageTrackerFacilitator: Usage tracking enabled
2019-03-21 20:23:26.587 21644-21660/fr.free.nrw.commons.beta D/TestExecutor: Adding listener androidx.test.internal.runner.listener.LogRunListener
2019-03-21 20:23:26.587 21644-21660/fr.free.nrw.commons.beta D/TestExecutor: Adding listener androidx.test.internal.runner.listener.InstrumentationResultPrinter
2019-03-21 20:23:26.587 21644-21660/fr.free.nrw.commons.beta D/TestExecutor: Adding listener androidx.test.internal.runner.listener.ActivityFinisherRunListener
2019-03-21 20:23:26.588 21644-21660/fr.free.nrw.commons.beta I/TestRunner: run started: 1 tests
2019-03-21 20:23:26.589 21644-21660/fr.free.nrw.commons.beta I/TestRunner: started: testAchievements(fr.free.nrw.commons.AchievementsActivityTest)
2019-03-21 20:23:26.591 21644-21644/fr.free.nrw.commons.beta I/MonitoringInstr: Activities that are still in CREATED to STOPPED: 0
2019-03-21 20:23:26.591 21644-21660/fr.free.nrw.commons.beta W/ActivityTestRule: getActivityIntent() returned null using default: Intent(Intent.ACTION_MAIN)
2019-03-21 20:23:26.598 21644-21644/fr.free.nrw.commons.beta W/ActivityThread: handleWindowVisibility: no activity for token android.os.BinderProxy@b8ed83
2019-03-21 20:23:26.625 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@17c4f39 in: PRE_ON_CREATE
2019-03-21 20:23:26.713 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@17c4f39 in: CREATED
2019-03-21 20:23:26.716 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@17c4f39 in: STARTED
2019-03-21 20:23:26.718 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/view/View;->computeFitSystemWindows(Landroid/graphics/Rect;Landroid/graphics/Rect;)Z (light greylist, reflection)
2019-03-21 20:23:26.718 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/view/ViewGroup;->makeOptionalFitsSystemWindows()V (light greylist, reflection)
2019-03-21 20:23:26.728 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@17c4f39 in: RESUMED
2019-03-21 20:23:26.728 21644-21644/fr.free.nrw.commons.beta D/OpenGLRenderer: HWUI GL Pipeline
2019-03-21 20:23:26.761 21644-21682/fr.free.nrw.commons.beta I/ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasWideColorDisplay retrieved: 0
2019-03-21 20:23:26.761 21644-21682/fr.free.nrw.commons.beta I/ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasHDRDisplay retrieved: 0
2019-03-21 20:23:26.761 21644-21682/fr.free.nrw.commons.beta I/OpenGLRenderer: Initialized EGL, version 1.4
2019-03-21 20:23:26.761 21644-21682/fr.free.nrw.commons.beta D/OpenGLRenderer: Swap behavior 1
2019-03-21 20:23:26.762 21644-21682/fr.free.nrw.commons.beta W/OpenGLRenderer: Failed to choose config with EGL_SWAP_BEHAVIOR_PRESERVED, retrying without...
2019-03-21 20:23:26.762 21644-21682/fr.free.nrw.commons.beta D/OpenGLRenderer: Swap behavior 0
2019-03-21 20:23:26.764 21644-21682/fr.free.nrw.commons.beta D/EGL_emulation: eglCreateContext: 0xecb85480: maj 2 min 0 rcv 2
2019-03-21 20:23:26.795 21644-21682/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb85480: ver 2 0 (tinfo 0xecb83800)
2019-03-21 20:23:26.814 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@17c4f39 in: PAUSED
2019-03-21 20:23:26.842 21644-21682/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb85480: ver 2 0 (tinfo 0xecb83800)
2019-03-21 20:23:26.885 21644-21644/fr.free.nrw.commons.beta W/ActivityThread: handleWindowVisibility: no activity for token android.os.BinderProxy@fb817d
2019-03-21 20:23:26.892 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@4a099be in: PRE_ON_CREATE
2019-03-21 20:23:26.903 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@4a099be in: CREATED
2019-03-21 20:23:26.905 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@4a099be in: STARTED
2019-03-21 20:23:26.906 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@4a099be in: RESUMED
2019-03-21 20:23:26.911 21644-21682/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb85480: ver 2 0 (tinfo 0xecb83800)
2019-03-21 20:23:26.941 21644-21644/fr.free.nrw.commons.beta D/android.widget.GridLayout: vertical constraints: y2-y0>=480, y2-y1<=236, y1-y0<=236 are inconsistent; permanently removing: y2-y1<=236. 
2019-03-21 20:23:26.964 21644-21682/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb85480: ver 2 0 (tinfo 0xecb83800)
2019-03-21 20:23:26.999 21644-21660/fr.free.nrw.commons.beta D/InputManagerEventInjectionStrategy: Creating injection strategy with input manager.
2019-03-21 20:23:26.999 21644-21660/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/hardware/input/InputManager;->getInstance()Landroid/hardware/input/InputManager; (light greylist, reflection)
2019-03-21 20:23:26.999 21644-21660/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/hardware/input/InputManager;->injectInputEvent(Landroid/view/InputEvent;I)Z (light greylist, reflection)
2019-03-21 20:23:26.999 21644-21660/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/hardware/input/InputManager;->INJECT_INPUT_EVENT_MODE_WAIT_FOR_FINISH:I (light greylist, reflection)
2019-03-21 20:23:27.002 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@17c4f39 in: STOPPED
2019-03-21 20:23:27.002 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.002 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.005 21644-21660/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/view/ViewConfiguration;->getDoubleTapMinTime()I (light greylist, reflection)
2019-03-21 20:23:27.013 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/os/MessageQueue;->next()Landroid/os/Message; (light greylist, reflection)
2019-03-21 20:23:27.013 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/os/MessageQueue;->mMessages:Landroid/os/Message; (light greylist, reflection)
2019-03-21 20:23:27.013 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/os/Message;->recycleUnchecked()V (light greylist, reflection)
2019-03-21 20:23:27.015 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/view/WindowManagerGlobal;->getInstance()Landroid/view/WindowManagerGlobal; (light greylist, reflection)
2019-03-21 20:23:27.015 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/view/WindowManagerGlobal;->mViews:Ljava/util/ArrayList; (light greylist, reflection)
2019-03-21 20:23:27.015 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/view/WindowManagerGlobal;->mParams:Ljava/util/ArrayList; (light greylist, reflection)
2019-03-21 20:23:27.018 21644-21644/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'single click' action on view with id: fr.free.nrw.commons.beta:id/finishTutorialButton
2019-03-21 20:23:27.070 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@4a099be in: PAUSED
2019-03-21 20:23:27.071 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.071 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.074 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@17c4f39 in: RESTARTED
2019-03-21 20:23:27.074 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.074 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.075 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@17c4f39 in: STARTED
2019-03-21 20:23:27.075 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.075 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.076 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@17c4f39 in: RESUMED
2019-03-21 20:23:27.076 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.076 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.118 21644-21682/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb85480: ver 2 0 (tinfo 0xecb83800)
2019-03-21 20:23:27.163 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@4a099be in: STOPPED
2019-03-21 20:23:27.163 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.163 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.166 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@4a099be in: DESTROYED
2019-03-21 20:23:27.166 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.166 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:27.351 21644-21644/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'replace text()' action on view with id: fr.free.nrw.commons.beta:id/loginUsername
2019-03-21 20:23:27.363 21644-21644/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'type text(domdomegg)' action on view with id: fr.free.nrw.commons.beta:id/loginUsername
2019-03-21 20:23:27.433 21644-21644/fr.free.nrw.commons.beta I/AssistStructure: Flattened final assist data: 4980 bytes, containing 1 windows, 17 views
2019-03-21 20:23:27.678 21644-21644/fr.free.nrw.commons.beta D/UiControllerImpl: Injecting string: "domdomegg"
2019-03-21 20:23:27.836 21644-21644/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'replace text()' action on view with id: fr.free.nrw.commons.beta:id/loginPassword
2019-03-21 20:23:27.849 21644-21644/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'type text(imgoingtochangethisnicetry)' action on view with id: fr.free.nrw.commons.beta:id/loginPassword
2019-03-21 20:23:27.914 21644-21644/fr.free.nrw.commons.beta I/AssistStructure: Flattened final assist data: 5012 bytes, containing 1 windows, 17 views
2019-03-21 20:23:28.139 21644-21644/fr.free.nrw.commons.beta D/UiControllerImpl: Injecting string: "imgoingtochangethisnicetry"
2019-03-21 20:23:28.591 21644-21644/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'close keyboard' action on view is a root view.
2019-03-21 20:23:28.975 21644-21644/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'single click' action on view with id: fr.free.nrw.commons.beta:id/loginButton
2019-03-21 20:23:29.027 21644-21644/fr.free.nrw.commons.beta D/LoginActivity: Login to start!
2019-03-21 20:23:29.075 21644-21682/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb85480: ver 2 0 (tinfo 0xecb83800)
2019-03-21 20:23:29.091 21644-21682/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb85480: ver 2 0 (tinfo 0xecb83800)
2019-03-21 20:23:29.324 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< START OF REQUEST LOGGING [/w/api.php] >>>>>>>>>>>>
2019-03-21 20:23:29.325 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: Request line:
     POST /w/api.php HTTP/1.1
2019-03-21 20:23:29.325 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< REQUEST PARAMS >>>>>>>>>>>>
2019-03-21 20:23:29.325 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< REQUEST PARAMS >>>>>>>>>>>>
2019-03-21 20:23:29.325 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< HEADERS >>>>>>>>>>>>
2019-03-21 20:23:29.326 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: Header >> Content-Length: 46
2019-03-21 20:23:29.326 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: Header >> Content-Type: application/x-www-form-urlencoded
2019-03-21 20:23:29.326 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: Header >> Host: commons.wikimedia.beta.wmflabs.org
2019-03-21 20:23:29.326 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: Header >> Connection: Keep-Alive
2019-03-21 20:23:29.327 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: Header >> User-Agent: Commons/2.10.1-debug-uiTests~3f32af24e (https://mediawiki.org/wiki/Apps/Commons) Android/9
2019-03-21 20:23:29.327 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< HEADERS >>>>>>>>>>>>
2019-03-21 20:23:29.327 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: Protocol version:
     HTTP/1.1
2019-03-21 20:23:29.327 21644-21692/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< END OF REQUEST LOGGING [/w/api.php] >>>>>>>>>>>>
2019-03-21 20:23:29.345 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/app/Activity;->mResultCode:I (light greylist, reflection)
2019-03-21 20:23:29.346 21644-21644/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/app/Activity;->mResultData:Landroid/content/Intent; (light greylist, reflection)
2019-03-21 20:23:29.346 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@17c4f39 in: PAUSED
2019-03-21 20:23:29.346 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:29.346 21644-21644/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@e7a83ff
2019-03-21 20:23:29.350 21644-21660/fr.free.nrw.commons.beta E/TestRunner: failed: testAchievements(fr.free.nrw.commons.AchievementsActivityTest)
2019-03-21 20:23:29.350 21644-21660/fr.free.nrw.commons.beta E/TestRunner: ----- begin exception -----
2019-03-21 20:23:29.350 21644-21660/fr.free.nrw.commons.beta E/TestRunner: androidx.test.espresso.NoMatchingViewException: No views in hierarchy found matching: with id: fr.free.nrw.commons.beta:id/drawer_layout
    
    View Hierarchy:
    +>DecorView{id=-1, visibility=VISIBLE, width=684, height=322, 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, layout-params={(0,0)(wrapxwrap) gr=CENTER sim={adjust=pan} ty=APPLICATION fmt=TRANSLUCENT wanim=0x10302f9
      fl=DIM_BEHIND ALT_FOCUSABLE_IM SPLIT_TOUCH HARDWARE_ACCELERATED}, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1} 
    |
    +->FrameLayout{id=-1, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@197ea07, tag=null, root-is-layout-requested=false, has-input-connection=false, x=32.0, y=32.0, child-count=2} 
    |
    +-->FrameLayout{id=16908290, res-name=content, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@461495d, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1} 
    |
    +--->AlertDialogLayout{id=16909162, res-name=parentPanel, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@7f83a1e, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=4} 
    |
    +---->LinearLayout{id=16909428, res-name=topPanel, visibility=VISIBLE, width=620, height=90, 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, layout-params=android.widget.LinearLayout$LayoutParams@4d94715, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2} 
    |
    +----->LinearLayout{id=16909418, res-name=title_template, visibility=VISIBLE, width=620, height=90, 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, layout-params=android.widget.LinearLayout$LayoutParams@a17d5b8, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2} 
    |
    +------>AppCompatImageView{id=16908294, res-name=icon, 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, layout-params=android.widget.LinearLayout$LayoutParams@3943f91, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0} 
    |
    +------>DialogTitle{id=16908701, res-name=alertTitle, visibility=VISIBLE, width=524, height=54, 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, layout-params=android.widget.LinearLayout$LayoutParams@ca36ef6, tag=null, root-is-layout-requested=false, has-input-connection=false, x=48.0, y=36.0, text=Logging in, input-type=0, ime-target=false, has-links=false} 
    |
    +----->Space{id=16909413, res-name=titleDividerNoCustom, 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,
2019-03-21 20:23:29.350 21644-21660/fr.free.nrw.commons.beta E/TestRunner: ----- end exception -----
2019-03-21 20:23:29.352 21644-21660/fr.free.nrw.commons.beta I/TestRunner: finished: testAchievements(fr.free.nrw.commons.AchievementsActivityTest)

@maskaravivek maskaravivek force-pushed the uiTests branch 2 times, most recently from 1c2537d to 58770c1 Compare March 23, 2019 16:45
@maskaravivek
Copy link
Member Author

I have added Android Test Orchestrator to allow running each test in isolation. Have configured it to clear app's state completely between tests.

All the tests pass now:

Screen Shot 2019-03-23 at 10 12 33 PM

Sporadically, doubleNavigateToExploreThenReturnHome fails. Have added a delay of 500ms before clicking a dav drawer item. That might fix the issue.

Suggested changes

With android test Orchestrator
@domdomegg domdomegg self-requested a review March 23, 2019 16:52
Copy link
Member

@domdomegg domdomegg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AchievementsActivityTest still fails for me. Everything else now works well.

Test logs
androidx.test.espresso.NoMatchingViewException: No views in hierarchy found matching: with id: fr.free.nrw.commons.beta:id/drawer_layout

View Hierarchy:
+>DecorView{id=-1, visibility=VISIBLE, width=684, height=322, 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, layout-params={(0,0)(wrapxwrap) gr=CENTER sim={adjust=pan} ty=APPLICATION fmt=TRANSLUCENT wanim=0x10302f9
fl=DIM_BEHIND ALT_FOCUSABLE_IM SPLIT_TOUCH HARDWARE_ACCELERATED}, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+->FrameLayout{id=-1, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@a42f7e7, tag=null, root-is-layout-requested=false, has-input-connection=false, x=32.0, y=32.0, child-count=2}
|
+-->FrameLayout{id=16908290, res-name=content, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@a2ba3d, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+--->AlertDialogLayout{id=16909162, res-name=parentPanel, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@82f1f7e, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=4}
|
+---->LinearLayout{id=16909428, res-name=topPanel, visibility=VISIBLE, width=620, height=90, 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, layout-params=android.widget.LinearLayout$LayoutParams@bfbf3f5, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2}
|
+----->LinearLayout{id=16909418, res-name=title_template, visibility=VISIBLE, width=620, height=90, 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, layout-params=android.widget.LinearLayout$LayoutParams@5f09018, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2}
|
+------>AppCompatImageView{id=16908294, res-name=icon, 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, layout-params=android.widget.LinearLayout$LayoutParams@de4da71, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+------>DialogTitle{id=16908701, res-name=alertTitle, visibility=VISIBLE, width=524, height=54, 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, layout-params=android.widget.LinearLayout$LayoutParams@965a056, tag=null, root-is-layout-requested=false, has-input-connection=false, x=48.0, y=36.0, text=Logging in, input-type=0, ime-target=false, has-links=false}
|
+----->Space{id=16909413, res-name=titleDividerNoCustom, 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, layout-params=android.widget.LinearLayout$LayoutParams@fa3a8d7, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+---->FrameLayout{id=16908813, res-name=contentPanel, 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, layout-params=android.widget.LinearLayout$LayoutParams@79bacad, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+----->ScrollView{id=16909256, res-name=scrollView, visibility=VISIBLE, 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, layout-params=android.widget.FrameLayout$LayoutParams@80ffb73, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+------>LinearLayout{id=-1, visibility=VISIBLE, 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, layout-params=android.widget.FrameLayout$LayoutParams@be4dbcf, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=3}
|
+------->Space{id=16909395, res-name=textSpacerNoTitle, 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, layout-params=android.widget.LinearLayout$LayoutParams@c84d95c, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+------->AppCompatTextView{id=16908299, res-name=message, 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, layout-params=android.widget.LinearLayout$LayoutParams@7f2c465, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+------->Space{id=16909394, res-name=textSpacerNoButtons, visibility=VISIBLE, 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, layout-params=android.widget.LinearLayout$LayoutParams@552953a, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+---->FrameLayout{id=16908820, res-name=customPanel, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.LinearLayout$LayoutParams@3342f48, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=90.0, child-count=1}
|
+----->FrameLayout{id=16908331, res-name=custom, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.FrameLayout$LayoutParams@444cb06, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+------>FrameLayout{id=-1, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.FrameLayout$LayoutParams@c00f7f4, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+------->LinearLayout{id=16908751, res-name=body, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.FrameLayout$LayoutParams@beea763, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2}
|
+-------->ProgressBar{id=16908301, res-name=progress, visibility=VISIBLE, width=96, height=96, 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, layout-params=android.widget.LinearLayout$LayoutParams@52f9f60, tag=null, root-is-layout-requested=false, has-input-connection=false, x=48.0, y=36.0}
|
+-------->AppCompatTextView{id=16908299, res-name=message, visibility=VISIBLE, width=380, height=38, 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, layout-params=android.widget.LinearLayout$LayoutParams@c164c19, tag=null, root-is-layout-requested=false, has-input-connection=false, x=192.0, y=65.0, text=Please wait…, input-type=0, ime-target=false, has-links=false}
|
+---->ScrollView{id=16908766, res-name=buttonPanel, 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=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@c9a56bf, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+----->ButtonBarLayout{id=-1, visibility=VISIBLE, 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, layout-params=android.widget.FrameLayout$LayoutParams@9f5fa78, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=4}
|
+------>AppCompatButton{id=16908315, res-name=button3, visibility=GONE, width=0, height=0, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=false, is-focusable=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@dc6551, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+------>Space{id=16909328, res-name=spacer, visibility=INVISIBLE, 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, layout-params=android.widget.LinearLayout$LayoutParams@25c01b6, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+------>AppCompatButton{id=16908314, res-name=button2, visibility=GONE, width=0, height=0, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=false, is-focusable=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@2765eb7, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+------>AppCompatButton{id=16908313, res-name=button1, visibility=GONE, width=0, height=0, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=false, is-focusable=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@5cc4624, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+-->ViewStub{id=16908682, res-name=action_mode_bar_stub, 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, layout-params=android.widget.FrameLayout$LayoutParams@931058d, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
at dalvik.system.VMStack.getThreadStackTrace(Native Method)
at java.lang.Thread.getStackTrace(Thread.java:1538)
at androidx.test.espresso.base.DefaultFailureHandler.getUserFriendlyError(DefaultFailureHandler.java:94)
at androidx.test.espresso.base.DefaultFailureHandler.handle(DefaultFailureHandler.java:57)
at androidx.test.espresso.ViewInteraction.waitForAndHandleInteractionResults(ViewInteraction.java:316)
at androidx.test.espresso.ViewInteraction.desugaredPerform(ViewInteraction.java:177)
at androidx.test.espresso.ViewInteraction.perform(ViewInteraction.java:118)
at fr.free.nrw.commons.AchievementsActivityTest.testAchievements(AchievementsActivityTest.kt:33)
at java.lang.reflect.Method.invoke(Native Method)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at androidx.test.internal.runner.junit4.statement.RunBefores.evaluate(RunBefores.java:80)
at androidx.test.rule.ActivityTestRule$ActivityStatement.evaluate(ActivityTestRule.java:531)
at org.junit.rules.RunRules.evaluate(RunRules.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at androidx.test.runner.AndroidJUnit4.run(AndroidJUnit4.java:104)
at org.junit.runners.Suite.runChild(Suite.java:128)
at org.junit.runners.Suite.runChild(Suite.java:27)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
at androidx.test.internal.runner.TestExecutor.execute(TestExecutor.java:56)
at androidx.test.runner.AndroidJUnitRunner.onStart(AndroidJUnitRunner.java:388)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:2145)
Logcat logs
2019-03-23 17:06:27.256 28484-28484/? I/rw.commons.bet: Not late-enabling -Xcheck:jni (already on)
2019-03-23 17:06:27.267 28484-28484/? W/rw.commons.bet: Unexpected CPU variant for X86 using defaults: x86
2019-03-23 17:06:27.280 28484-28491/? E/rw.commons.bet: Failed to send DDMS packet REAQ to debugger (-1 of 20): Broken pipe
2019-03-23 17:06:27.282 28484-28484/? W/ActivityThread: Package uses different ABI(s) than its instrumentation: package[fr.free.nrw.commons.beta]: x86, null instrumentation[fr.free.nrw.commons.beta.test]: null, null
2019-03-23 17:06:27.283 28484-28484/? I/rw.commons.bet: The ClassLoaderContext is a special shared library.
2019-03-23 17:06:27.483 28484-28484/? E/LoadedApk: Unable to instantiate appComponentFactory
    java.lang.ClassNotFoundException: Didn't find class "fr.free.nrw.commons.beta.commons" on path: DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/base.apk", zip file "/data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/base.apk"],nativeLibraryDirectories=[/data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/lib/x86, /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/lib/x86, /data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/base.apk!/lib/x86, /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/base.apk!/lib/x86, /system/lib]]
        at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:134)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
        at android.app.LoadedApk.createAppFactory(LoadedApk.java:226)
        at android.app.LoadedApk.createOrUpdateClassLoaderLocked(LoadedApk.java:731)
        at android.app.LoadedApk.getClassLoader(LoadedApk.java:810)
        at android.app.LoadedApk.getResources(LoadedApk.java:1032)
        at android.app.ContextImpl.createAppContext(ContextImpl.java:2345)
        at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5749)
        at android.app.ActivityThread.access$1100(ActivityThread.java:199)
        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1650)
        at android.os.Handler.dispatchMessage(Handler.java:106)
        at android.os.Looper.loop(Looper.java:193)
        at android.app.ActivityThread.main(ActivityThread.java:6669)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
2019-03-23 17:06:27.489 28484-28484/? I/chatty: uid=10085(fr.free.nrw.commons.beta) identical 3 lines
2019-03-23 17:06:27.489 28484-28484/? I/rw.commons.bet: The ClassLoaderContext is a special shared library.
2019-03-23 17:06:27.691 28484-28484/? W/rw.commons.bet: Accessing hidden method Landroid/app/Instrumentation;->execStartActivity(Landroid/content/Context;Landroid/os/IBinder;Landroid/os/IBinder;Landroid/app/Activity;Landroid/content/Intent;ILandroid/os/Bundle;)Landroid/app/Instrumentation$ActivityResult; (light greylist, linking)
2019-03-23 17:06:27.691 28484-28484/? W/rw.commons.bet: Accessing hidden method Landroid/app/Instrumentation;->execStartActivity(Landroid/content/Context;Landroid/os/IBinder;Landroid/os/IBinder;Ljava/lang/String;Landroid/content/Intent;ILandroid/os/Bundle;)Landroid/app/Instrumentation$ActivityResult; (light greylist, linking)
2019-03-23 17:06:27.722 28484-28484/? I/MonitoringInstr: Instrumentation started!
2019-03-23 17:06:27.723 28484-28484/? I/MonitoringInstr: Setting context classloader to 'dalvik.system.PathClassLoader[DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/base.apk", zip file "/data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/base.apk"],nativeLibraryDirectories=[/data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/lib/x86, /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/lib/x86, /data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/base.apk!/lib/x86, /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/base.apk!/lib/x86, /system/lib]]]', Original: 'dalvik.system.PathClassLoader[DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/base.apk", zip file "/data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/base.apk"],nativeLibraryDirectories=[/data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/lib/x86, /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/lib/x86, /data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/base.apk!/lib/x86, /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/base.apk!/lib/x86, /system/lib]]]'
2019-03-23 17:06:27.788 28484-28484/? I/ACRA: Migrating unsent ACRA reports to new file locations
2019-03-23 17:06:27.788 28484-28484/? I/ACRA: Migrated 0 unsent reports
2019-03-23 17:06:27.789 28484-28484/? I/ACRA: Converting unsent ACRA reports to json
2019-03-23 17:06:27.790 28484-28484/? I/ACRA: Converted 0 unsent reports
2019-03-23 17:06:27.790 28484-28484/? I/ACRA: ACRA is enabled for fr.free.nrw.commons.beta, initializing...
2019-03-23 17:06:27.813 28484-28484/? D/NetworkSecurityConfig: No Network Security Config specified, using platform default
2019-03-23 17:06:27.834 28484-28484/? D/SoLoader: init start
2019-03-23 17:06:27.834 28484-28484/? D/SoLoader: adding system library source: /vendor/lib
2019-03-23 17:06:27.835 28484-28484/? D/SoLoader: adding system library source: /system/lib
2019-03-23 17:06:27.835 28484-28484/? D/SoLoader: adding application source: com.facebook.soloader.DirectorySoSource[root = /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/lib/x86 flags = 0]
2019-03-23 17:06:27.836 28484-28484/? D/SoLoader: adding backup source from : com.facebook.soloader.ApkSoSource[root = /data/data/fr.free.nrw.commons.beta/lib-main flags = 1]
2019-03-23 17:06:27.836 28484-28484/? D/SoLoader: Preparing SO source: com.facebook.soloader.DirectorySoSource[root = /system/lib flags = 2]
2019-03-23 17:06:27.836 28484-28484/? D/SoLoader: Preparing SO source: com.facebook.soloader.DirectorySoSource[root = /vendor/lib flags = 2]
2019-03-23 17:06:27.836 28484-28484/? D/SoLoader: Preparing SO source: com.facebook.soloader.DirectorySoSource[root = /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/lib/x86 flags = 0]
2019-03-23 17:06:27.836 28484-28484/? D/SoLoader: Preparing SO source: com.facebook.soloader.ApkSoSource[root = /data/data/fr.free.nrw.commons.beta/lib-main flags = 1]
2019-03-23 17:06:27.836 28484-28484/? V/fb-UnpackingSoSource: locked dso store /data/user/0/fr.free.nrw.commons.beta/lib-main
2019-03-23 17:06:27.837 28484-28484/? V/fb-UnpackingSoSource: deps mismatch on deps store: regenerating
2019-03-23 17:06:27.837 28484-28484/? V/fb-UnpackingSoSource: so store dirty: regenerating
2019-03-23 17:06:27.858 28484-28484/? D/ApkSoSource: not allowing consideration of lib/x86/libimagepipeline.so: deferring to libdir
2019-03-23 17:06:27.858 28484-28484/? D/ApkSoSource: not allowing consideration of lib/x86/libmapbox-gl.so: deferring to libdir
2019-03-23 17:06:27.858 28484-28484/? D/ApkSoSource: not allowing consideration of lib/x86/libnative-filters.so: deferring to libdir
2019-03-23 17:06:27.858 28484-28484/? D/ApkSoSource: not allowing consideration of lib/x86/libnative-imagetranscoder.so: deferring to libdir
2019-03-23 17:06:27.858 28484-28484/? V/fb-UnpackingSoSource: regenerating DSO store com.facebook.soloader.ApkSoSource
2019-03-23 17:06:27.858 28484-28484/? V/fb-UnpackingSoSource: Finished regenerating DSO store com.facebook.soloader.ApkSoSource
2019-03-23 17:06:27.859 28484-28484/? V/fb-UnpackingSoSource: starting syncer worker
2019-03-23 17:06:27.862 28484-28484/? V/fb-UnpackingSoSource: releasing dso store lock for /data/user/0/fr.free.nrw.commons.beta/lib-main (from syncer thread)
2019-03-23 17:06:27.862 28484-28484/? V/fb-UnpackingSoSource: not releasing dso store lock for /data/user/0/fr.free.nrw.commons.beta/lib-main (syncer thread started)
2019-03-23 17:06:27.862 28484-28484/? D/SoLoader: init finish: 4 SO sources prepared
2019-03-23 17:06:27.862 28484-28484/? D/SoLoader: init exiting
2019-03-23 17:06:27.871 28484-28504/? I/stetho: Listening on @stetho_fr.free.nrw.commons.beta_devtools_remote
2019-03-23 17:06:27.881 28484-28484/? I/OrchestrationListener: OrchestrationListener connected to service
2019-03-23 17:06:27.882 28484-28484/? I/MonitoringInstr: No JSBridge.
2019-03-23 17:06:27.882 28484-28507/? I/MonitoringInstr: Setting context classloader to 'dalvik.system.PathClassLoader[DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/base.apk", zip file "/data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/base.apk"],nativeLibraryDirectories=[/data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/lib/x86, /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/lib/x86, /data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/base.apk!/lib/x86, /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/base.apk!/lib/x86, /system/lib]]]', Original: 'dalvik.system.PathClassLoader[DexPathList[[zip file "/system/framework/android.test.runner.jar", zip file "/system/framework/android.test.mock.jar", zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/base.apk", zip file "/data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/base.apk"],nativeLibraryDirectories=[/data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/lib/x86, /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/lib/x86, /data/app/fr.free.nrw.commons.beta.test-UmpukMtxHIKUInEm0g0aLg==/base.apk!/lib/x86, /data/app/fr.free.nrw.commons.beta-9IdXltvf9ISbudWSprWmzA==/base.apk!/lib/x86, /system/lib]]]'
2019-03-23 17:06:27.890 28484-28507/? I/UsageTrackerFacilitator: Usage tracking disabled
2019-03-23 17:06:27.897 28484-28507/? D/TestExecutor: Adding listener androidx.test.internal.runner.listener.LogRunListener
2019-03-23 17:06:27.897 28484-28507/? D/TestExecutor: Adding listener androidx.test.orchestrator.instrumentationlistener.OrchestratedInstrumentationListener
2019-03-23 17:06:27.897 28484-28507/? D/TestExecutor: Adding listener androidx.test.internal.runner.listener.ActivityFinisherRunListener
2019-03-23 17:06:27.899 28484-28507/? I/TestRunner: run started: 1 tests
2019-03-23 17:06:27.902 28484-28507/? I/TestRunner: started: testAchievements(fr.free.nrw.commons.AchievementsActivityTest)
2019-03-23 17:06:27.903 28484-28484/? I/MonitoringInstr: Activities that are still in CREATED to STOPPED: 0
2019-03-23 17:06:27.904 28484-28507/? W/ActivityTestRule: getActivityIntent() returned null using default: Intent(Intent.ACTION_MAIN)
2019-03-23 17:06:27.912 28484-28484/? W/ActivityThread: handleWindowVisibility: no activity for token android.os.BinderProxy@127497e
2019-03-23 17:06:27.922 28484-28484/? D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@ceb072c in: PRE_ON_CREATE
2019-03-23 17:06:28.012 28484-28484/? D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@ceb072c in: CREATED
2019-03-23 17:06:28.015 28484-28484/? D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@ceb072c in: STARTED
2019-03-23 17:06:28.017 28484-28484/? W/rw.commons.bet: Accessing hidden method Landroid/view/View;->computeFitSystemWindows(Landroid/graphics/Rect;Landroid/graphics/Rect;)Z (light greylist, reflection)
2019-03-23 17:06:28.017 28484-28484/? W/rw.commons.bet: Accessing hidden method Landroid/view/ViewGroup;->makeOptionalFitsSystemWindows()V (light greylist, reflection)
2019-03-23 17:06:28.027 28484-28484/? D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@ceb072c in: RESUMED
2019-03-23 17:06:28.027 28484-28484/? D/OpenGLRenderer: HWUI GL Pipeline
2019-03-23 17:06:28.061 28484-28513/? I/ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasWideColorDisplay retrieved: 0
2019-03-23 17:06:28.061 28484-28513/? I/ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasHDRDisplay retrieved: 0
2019-03-23 17:06:28.061 28484-28513/? I/OpenGLRenderer: Initialized EGL, version 1.4
2019-03-23 17:06:28.061 28484-28513/? D/OpenGLRenderer: Swap behavior 1
2019-03-23 17:06:28.061 28484-28513/? W/OpenGLRenderer: Failed to choose config with EGL_SWAP_BEHAVIOR_PRESERVED, retrying without...
2019-03-23 17:06:28.061 28484-28513/? D/OpenGLRenderer: Swap behavior 0
2019-03-23 17:06:28.063 28484-28513/? D/EGL_emulation: eglCreateContext: 0xecb857e0: maj 2 min 0 rcv 2
2019-03-23 17:06:28.106 28484-28513/? D/EGL_emulation: eglMakeCurrent: 0xecb857e0: ver 2 0 (tinfo 0xecb839b0)
2019-03-23 17:06:28.124 28484-28484/? D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@ceb072c in: PAUSED
2019-03-23 17:06:28.134 28484-28513/? D/EGL_emulation: eglMakeCurrent: 0xecb857e0: ver 2 0 (tinfo 0xecb839b0)
2019-03-23 17:06:28.207 28484-28484/? W/ActivityThread: handleWindowVisibility: no activity for token android.os.BinderProxy@5f78140
2019-03-23 17:06:28.215 28484-28484/? D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@f3e6335 in: PRE_ON_CREATE
2019-03-23 17:06:28.228 28484-28484/? D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@f3e6335 in: CREATED
2019-03-23 17:06:28.230 28484-28484/? D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@f3e6335 in: STARTED
2019-03-23 17:06:28.231 28484-28484/? D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@f3e6335 in: RESUMED
2019-03-23 17:06:28.265 28484-28484/? D/android.widget.GridLayout: vertical constraints: y2-y0>=480, y2-y1<=236, y1-y0<=236 are inconsistent; permanently removing: y2-y1<=236. 
2019-03-23 17:06:28.288 28484-28513/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb857e0: ver 2 0 (tinfo 0xecb839b0)
2019-03-23 17:06:28.336 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@ceb072c in: STOPPED
2019-03-23 17:06:28.336 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.336 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.343 28484-28507/fr.free.nrw.commons.beta D/InputManagerEventInjectionStrategy: Creating injection strategy with input manager.
2019-03-23 17:06:28.343 28484-28507/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/hardware/input/InputManager;->getInstance()Landroid/hardware/input/InputManager; (light greylist, reflection)
2019-03-23 17:06:28.343 28484-28507/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/hardware/input/InputManager;->injectInputEvent(Landroid/view/InputEvent;I)Z (light greylist, reflection)
2019-03-23 17:06:28.343 28484-28507/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/hardware/input/InputManager;->INJECT_INPUT_EVENT_MODE_WAIT_FOR_FINISH:I (light greylist, reflection)
2019-03-23 17:06:28.349 28484-28507/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/view/ViewConfiguration;->getDoubleTapMinTime()I (light greylist, reflection)
2019-03-23 17:06:28.353 28484-28484/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/os/MessageQueue;->next()Landroid/os/Message; (light greylist, reflection)
2019-03-23 17:06:28.353 28484-28484/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/os/MessageQueue;->mMessages:Landroid/os/Message; (light greylist, reflection)
2019-03-23 17:06:28.353 28484-28484/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/os/Message;->recycleUnchecked()V (light greylist, reflection)
2019-03-23 17:06:28.355 28484-28484/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden method Landroid/view/WindowManagerGlobal;->getInstance()Landroid/view/WindowManagerGlobal; (light greylist, reflection)
2019-03-23 17:06:28.355 28484-28484/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/view/WindowManagerGlobal;->mViews:Ljava/util/ArrayList; (light greylist, reflection)
2019-03-23 17:06:28.355 28484-28484/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/view/WindowManagerGlobal;->mParams:Ljava/util/ArrayList; (light greylist, reflection)
2019-03-23 17:06:28.359 28484-28484/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'single click' action on view with id: fr.free.nrw.commons.beta:id/finishTutorialButton
2019-03-23 17:06:28.409 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@f3e6335 in: PAUSED
2019-03-23 17:06:28.409 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.410 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.413 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@ceb072c in: RESTARTED
2019-03-23 17:06:28.413 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.413 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.413 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@ceb072c in: STARTED
2019-03-23 17:06:28.413 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.413 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.414 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@ceb072c in: RESUMED
2019-03-23 17:06:28.414 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.414 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.445 28484-28513/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb857e0: ver 2 0 (tinfo 0xecb839b0)
2019-03-23 17:06:28.480 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@f3e6335 in: STOPPED
2019-03-23 17:06:28.480 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.480 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.483 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.WelcomeActivity@f3e6335 in: DESTROYED
2019-03-23 17:06:28.483 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.483 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:28.675 28484-28484/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'replace text()' action on view with id: fr.free.nrw.commons.beta:id/loginUsername
2019-03-23 17:06:28.696 28484-28484/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'type text(domdomegg)' action on view with id: fr.free.nrw.commons.beta:id/loginUsername
2019-03-23 17:06:28.767 28484-28484/fr.free.nrw.commons.beta I/AssistStructure: Flattened final assist data: 4980 bytes, containing 1 windows, 17 views
2019-03-23 17:06:29.006 28484-28484/fr.free.nrw.commons.beta D/UiControllerImpl: Injecting string: "domdomegg"
2019-03-23 17:06:29.168 28484-28484/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'replace text()' action on view with id: fr.free.nrw.commons.beta:id/loginPassword
2019-03-23 17:06:29.182 28484-28484/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'type text(notMyRealPassword)' action on view with id: fr.free.nrw.commons.beta:id/loginPassword
2019-03-23 17:06:29.242 28484-28484/fr.free.nrw.commons.beta I/AssistStructure: Flattened final assist data: 5012 bytes, containing 1 windows, 17 views
2019-03-23 17:06:29.473 28484-28484/fr.free.nrw.commons.beta D/UiControllerImpl: Injecting string: "notMyRealPassword"
2019-03-23 17:06:29.955 28484-28484/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'close keyboard' action on view is a root view.
2019-03-23 17:06:30.307 28484-28484/fr.free.nrw.commons.beta I/ViewInteraction: Performing 'single click' action on view with id: fr.free.nrw.commons.beta:id/loginButton
2019-03-23 17:06:30.357 28484-28484/fr.free.nrw.commons.beta D/LoginActivity: Login to start!
2019-03-23 17:06:30.407 28484-28513/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb857e0: ver 2 0 (tinfo 0xecb839b0)
2019-03-23 17:06:30.423 28484-28513/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb857e0: ver 2 0 (tinfo 0xecb839b0)
2019-03-23 17:06:30.641 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< START OF REQUEST LOGGING [/w/api.php] >>>>>>>>>>>>
2019-03-23 17:06:30.642 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: Request line:
     POST /w/api.php HTTP/1.1
2019-03-23 17:06:30.642 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< REQUEST PARAMS >>>>>>>>>>>>
2019-03-23 17:06:30.642 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< REQUEST PARAMS >>>>>>>>>>>>
2019-03-23 17:06:30.643 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< HEADERS >>>>>>>>>>>>
2019-03-23 17:06:30.643 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: Header >> Content-Length: 46
2019-03-23 17:06:30.644 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: Header >> Content-Type: application/x-www-form-urlencoded
2019-03-23 17:06:30.644 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: Header >> Host: commons.wikimedia.beta.wmflabs.org
2019-03-23 17:06:30.645 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: Header >> Connection: Keep-Alive
2019-03-23 17:06:30.645 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: Header >> User-Agent: Commons/2.10.1-debug-uiTests~58770c136 (https://mediawiki.org/wiki/Apps/Commons) Android/9
2019-03-23 17:06:30.646 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< HEADERS >>>>>>>>>>>>
2019-03-23 17:06:30.646 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: Protocol version:
     HTTP/1.1
2019-03-23 17:06:30.647 28484-28524/fr.free.nrw.commons.beta V/NetworkInterceptors: <<<<<<<<<<<<<< END OF REQUEST LOGGING [/w/api.php] >>>>>>>>>>>>
2019-03-23 17:06:30.683 28484-28484/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/app/Activity;->mResultCode:I (light greylist, reflection)
2019-03-23 17:06:30.684 28484-28484/fr.free.nrw.commons.beta W/rw.commons.bet: Accessing hidden field Landroid/app/Activity;->mResultData:Landroid/content/Intent; (light greylist, reflection)
2019-03-23 17:06:30.684 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@ceb072c in: PAUSED
2019-03-23 17:06:30.685 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: running callback: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:30.685 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: callback completes: androidx.test.rule.ActivityTestRule$LifecycleCallback@15bf2a
2019-03-23 17:06:30.694 28484-28507/fr.free.nrw.commons.beta E/TestRunner: failed: testAchievements(fr.free.nrw.commons.AchievementsActivityTest)
2019-03-23 17:06:30.694 28484-28507/fr.free.nrw.commons.beta E/TestRunner: ----- begin exception -----
2019-03-23 17:06:30.696 28484-28507/fr.free.nrw.commons.beta E/TestRunner: androidx.test.espresso.NoMatchingViewException: No views in hierarchy found matching: with id: fr.free.nrw.commons.beta:id/drawer_layout
    
    View Hierarchy:
    +>DecorView{id=-1, visibility=VISIBLE, width=684, height=322, 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, layout-params={(0,0)(wrapxwrap) gr=CENTER sim={adjust=pan} ty=APPLICATION fmt=TRANSLUCENT wanim=0x10302f9
      fl=DIM_BEHIND ALT_FOCUSABLE_IM SPLIT_TOUCH HARDWARE_ACCELERATED}, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1} 
    |
    +->FrameLayout{id=-1, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@c61080f, tag=null, root-is-layout-requested=false, has-input-connection=false, x=32.0, y=32.0, child-count=2} 
    |
    +-->FrameLayout{id=16908290, res-name=content, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@dff6aa5, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1} 
    |
    +--->AlertDialogLayout{id=16909162, res-name=parentPanel, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@24a6846, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=4} 
    |
    +---->LinearLayout{id=16909428, res-name=topPanel, visibility=VISIBLE, width=620, height=90, 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, layout-params=android.widget.LinearLayout$LayoutParams@461495d, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2} 
    |
    +----->LinearLayout{id=16909418, res-name=title_template, visibility=VISIBLE, width=620, height=90, 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, layout-params=android.widget.LinearLayout$LayoutParams@41652a0, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2} 
    |
    +------>AppCompatImageView{id=16908294, res-name=icon, 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, layout-params=android.widget.LinearLayout$LayoutParams@26e1e59, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0} 
    |
    +------>DialogTitle{id=16908701, res-name=alertTitle, visibility=VISIBLE, width=524, height=54, 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, layout-params=android.widget.LinearLayout$LayoutParams@7f83a1e, tag=null, root-is-layout-requested=false, has-input-connection=false, x=48.0, y=36.0, text=Logging in, input-type=0, ime-target=false, has-links=false} 
    |
    +----->Space{id=16909413, res-name=titleDividerNoCustom, 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,
2019-03-23 17:06:30.696 28484-28507/fr.free.nrw.commons.beta E/TestRunner: ----- end exception -----
2019-03-23 17:06:30.703 28484-28507/fr.free.nrw.commons.beta I/TestRunner: finished: testAchievements(fr.free.nrw.commons.AchievementsActivityTest)
2019-03-23 17:06:30.711 28484-28484/fr.free.nrw.commons.beta I/MonitoringInstr: Activities that are still in CREATED to STOPPED: 1
2019-03-23 17:06:30.712 28484-28507/fr.free.nrw.commons.beta I/MonitoringInstr: Unstopped activity count: 1
2019-03-23 17:06:30.762 28484-28507/fr.free.nrw.commons.beta I/MonitoringInstr: Unstopped activity count: 1
2019-03-23 17:06:30.805 28484-28513/fr.free.nrw.commons.beta D/EGL_emulation: eglMakeCurrent: 0xecb857e0: ver 2 0 (tinfo 0xecb839b0)
2019-03-23 17:06:30.807 28484-28484/fr.free.nrw.commons.beta D/AutofillManager: onActivityFinishing(): calling cancelLocked()
2019-03-23 17:06:30.807 28484-28484/fr.free.nrw.commons.beta D/LifecycleMonitor: Lifecycle status change: fr.free.nrw.commons.auth.LoginActivity@ceb072c in: STOPPED
2019-03-23 17:06:30.813 28484-28507/fr.free.nrw.commons.beta I/TestRunner: run finished: 1 tests, 1 failed, 0 ignored
2019-03-23 17:06:30.822 28484-28507/fr.free.nrw.commons.beta I/MonitoringInstr: waitForActivitiesToComplete() took: 0ms

app/build.gradle Outdated
@@ -74,6 +74,8 @@ dependencies {
androidTestImplementation 'androidx.annotation:annotation:1.0.2'
androidTestImplementation 'com.squareup.okhttp3:mockwebserver:3.10.0'
androidTestImplementation 'org.mockito:mockito-core:2.10.0'
androidTestImplementation 'androidx.test:runner:1.1.0'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is a duplicate import - see line 72

@maskaravivek
Copy link
Member Author

@domdomegg For achievements can you try the following test. I am unable to reproduce it.

@Test
    fun testAchievements() {
        UITestHelper.sleep(4000)
        onView(withId(R.id.drawer_layout)).perform(DrawerActions.open())
        UITestHelper.sleep(500)
        onView(withId(R.id.user_icon)).perform(click())

        Intents.intended(hasComponent(AchievementsActivity::class.java.name))
    }

@domdomegg
Copy link
Member

@domdomegg For achievements can you try the following test. I am unable to reproduce it.

That fixes it. It also works without the sleep between opening the drawer and clicking the tab. It's probably best to put that delay in the loginUser method.

I had a thought about this, and tried to figure out why uploadTest had no issues. Just as I've been thinking this it's also tripped up with the same problems - probably also the same issue i.e. loginUser not being given time until it logs in.

Ideally we'd use something like idling resources for this, but delays are okay for now I guess.

Logs
androidx.test.espresso.NoMatchingViewException: No views in hierarchy found matching: (with id: fr.free.nrw.commons.beta:id/fab_plus and is displayed on the screen to the user)

View Hierarchy:
+>DecorView{id=-1, visibility=VISIBLE, width=684, height=322, 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, layout-params={(0,0)(wrapxwrap) gr=CENTER sim={adjust=pan} ty=APPLICATION fmt=TRANSLUCENT wanim=0x10302f9
fl=DIM_BEHIND ALT_FOCUSABLE_IM SPLIT_TOUCH HARDWARE_ACCELERATED}, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+->FrameLayout{id=-1, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@de4da71, tag=null, root-is-layout-requested=false, has-input-connection=false, x=32.0, y=32.0, child-count=2}
|
+-->FrameLayout{id=16908290, res-name=content, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@965a056, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+--->AlertDialogLayout{id=16909162, res-name=parentPanel, visibility=VISIBLE, width=620, height=258, 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, layout-params=android.widget.FrameLayout$LayoutParams@79bacad, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=4}
|
+---->LinearLayout{id=16909428, res-name=topPanel, visibility=VISIBLE, width=620, height=90, 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, layout-params=android.widget.LinearLayout$LayoutParams@80ffb73, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2}
|
+----->LinearLayout{id=16909418, res-name=title_template, visibility=VISIBLE, width=620, height=90, 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, layout-params=android.widget.LinearLayout$LayoutParams@47366a9, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2}
|
+------>AppCompatImageView{id=16908294, res-name=icon, 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, layout-params=android.widget.LinearLayout$LayoutParams@e20642e, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+------>DialogTitle{id=16908701, res-name=alertTitle, visibility=VISIBLE, width=524, height=54, 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, layout-params=android.widget.LinearLayout$LayoutParams@be4dbcf, tag=null, root-is-layout-requested=false, has-input-connection=false, x=48.0, y=36.0, text=Logging in, input-type=0, ime-target=false, has-links=false}
|
+----->Space{id=16909413, res-name=titleDividerNoCustom, 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, layout-params=android.widget.LinearLayout$LayoutParams@c84d95c, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+---->FrameLayout{id=16908813, res-name=contentPanel, 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, layout-params=android.widget.LinearLayout$LayoutParams@552953a, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+----->ScrollView{id=16909256, res-name=scrollView, visibility=VISIBLE, 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, layout-params=android.widget.FrameLayout$LayoutParams@3342f48, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+------>LinearLayout{id=-1, visibility=VISIBLE, 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, layout-params=android.widget.FrameLayout$LayoutParams@c00f7f4, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=3}
|
+------->Space{id=16909395, res-name=textSpacerNoTitle, 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, layout-params=android.widget.LinearLayout$LayoutParams@2ae1b1d, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+------->AppCompatTextView{id=16908299, res-name=message, 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, layout-params=android.widget.LinearLayout$LayoutParams@5d29192, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+------->Space{id=16909394, res-name=textSpacerNoButtons, visibility=VISIBLE, 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, layout-params=android.widget.LinearLayout$LayoutParams@beea763, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+---->FrameLayout{id=16908820, res-name=customPanel, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.LinearLayout$LayoutParams@52f9f60, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=90.0, child-count=1}
|
+----->FrameLayout{id=16908331, res-name=custom, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.FrameLayout$LayoutParams@c164c19, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+------>FrameLayout{id=-1, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.FrameLayout$LayoutParams@50434de, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+------->LinearLayout{id=16908751, res-name=body, visibility=VISIBLE, width=620, height=168, 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, layout-params=android.widget.FrameLayout$LayoutParams@c9a56bf, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2}
|
+-------->ProgressBar{id=16908301, res-name=progress, visibility=VISIBLE, width=96, height=96, 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, layout-params=android.widget.LinearLayout$LayoutParams@adf518c, tag=null, root-is-layout-requested=false, has-input-connection=false, x=48.0, y=36.0}
|
+-------->AppCompatTextView{id=16908299, res-name=message, visibility=VISIBLE, width=380, height=38, 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, layout-params=android.widget.LinearLayout$LayoutParams@a3690d5, tag=null, root-is-layout-requested=false, has-input-connection=false, x=192.0, y=65.0, text=Please wait…, input-type=0, ime-target=false, has-links=false}
|
+---->ScrollView{id=16908766, res-name=buttonPanel, 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=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@8279fdb, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=1}
|
+----->ButtonBarLayout{id=-1, visibility=VISIBLE, 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, layout-params=android.widget.FrameLayout$LayoutParams@5cc4624, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=4}
|
+------>AppCompatButton{id=16908315, res-name=button3, visibility=GONE, width=0, height=0, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=false, is-focusable=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@931058d, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+------>Space{id=16909328, res-name=spacer, visibility=INVISIBLE, 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, layout-params=android.widget.LinearLayout$LayoutParams@19e8342, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+------>AppCompatButton{id=16908314, res-name=button2, visibility=GONE, width=0, height=0, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=false, is-focusable=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@3882f53, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+------>AppCompatButton{id=16908313, res-name=button1, visibility=GONE, width=0, height=0, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=false, is-focusable=true, is-layout-requested=true, is-selected=false, layout-params=android.widget.LinearLayout$LayoutParams@c99a090, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, text=, input-type=0, ime-target=false, has-links=false}
|
+-->ViewStub{id=16908682, res-name=action_mode_bar_stub, 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, layout-params=android.widget.FrameLayout$LayoutParams@bb56d89, tag=null, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
at dalvik.system.VMStack.getThreadStackTrace(Native Method)
at java.lang.Thread.getStackTrace(Thread.java:1538)
at androidx.test.espresso.base.DefaultFailureHandler.getUserFriendlyError(DefaultFailureHandler.java:94)
at androidx.test.espresso.base.DefaultFailureHandler.handle(DefaultFailureHandler.java:57)
at androidx.test.espresso.ViewInteraction.waitForAndHandleInteractionResults(ViewInteraction.java:316)
at androidx.test.espresso.ViewInteraction.desugaredPerform(ViewInteraction.java:177)
at androidx.test.espresso.ViewInteraction.perform(ViewInteraction.java:118)
at fr.free.nrw.commons.UploadTest.uploadTest(UploadTest.kt:124)
at java.lang.reflect.Method.invoke(Native Method)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at androidx.test.internal.runner.junit4.statement.RunBefores.evaluate(RunBefores.java:80)
at androidx.test.internal.runner.junit4.statement.RunAfters.evaluate(RunAfters.java:61)
at androidx.test.rule.GrantPermissionRule$RequestPermissionStatement.evaluate(GrantPermissionRule.java:134)
at androidx.test.rule.ActivityTestRule$ActivityStatement.evaluate(ActivityTestRule.java:531)
at org.junit.rules.RunRules.evaluate(RunRules.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at androidx.test.runner.AndroidJUnit4.run(AndroidJUnit4.java:104)
at org.junit.runners.Suite.runChild(Suite.java:128)
at org.junit.runners.Suite.runChild(Suite.java:27)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
at androidx.test.internal.runner.TestExecutor.execute(TestExecutor.java:56)
at androidx.test.runner.AndroidJUnitRunner.onStart(AndroidJUnitRunner.java:388)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:2145)

val username = BuildConfig.TEST_USERNAME
if (StringUtils.isNullOrWhiteSpace(username) || username == "null") {
throw NotImplementedError("Configure your beta account's username")
//return ""
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line can be removed

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I kept this line to indicate that you need to return your username. I can remove it if it is not needed.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry I meant keep in the throwing the errors, just remove the return statements (on line 51 here)

val password = BuildConfig.TEST_PASSWORD
if (StringUtils.isNullOrWhiteSpace(password) || password == "null") {
throw NotImplementedError("Configure your beta account's password")
return ""
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line can be removed

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And on line 59 here

@maskaravivek
Copy link
Member Author

Ideally we'd use something like idling resources for this, but delays are okay for now I guess.

I agree that using idling resources would be the best way to do it. I will open a separate issue for it so that someone can take it up. :)

@maskaravivek
Copy link
Member Author

@domdomegg I have made the suggested changes. And have run the tests locally.

Screen Shot 2019-03-23 at 11 07 53 PM

@domdomegg domdomegg self-requested a review March 23, 2019 21:28
Copy link
Member

@domdomegg domdomegg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works perfectly, thanks so much. Glad achievements test fixed now :)

@domdomegg domdomegg merged commit f7e6b20 into commons-app:master Mar 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants