Fixed
Status Update
Comments
nk...@google.com <nk...@google.com>
nk...@google.com <nk...@google.com> #2
I have also seen this issue, careful analysis has shown it appears to be related to the canary version of the caf_receiver framework.
In debug mode you will see: Load failed: cast.o.media.Il.create is not a function
This function appears to be missing inhttps://www.gstatic.com/cast/sdk/libs/caf_receiver/canary/cast_receiver_framework.js , the code in the non-canary framework, located at https://www.gstatic.com/cast/sdk/libs/caf_receiver/v3/cast_receiver_framework.js doesn't have this issue.
In debug mode you will see: Load failed: cast.o.media.Il.create is not a function
This function appears to be missing in
Description
Version used:
What steps will reproduce the problem?
1. Call IntentsTestRule.launchActivity, and then finish activity
2. Call IntentsTestRule.launchActivity again in the same test case
3. Crash
How are you running your tests (via Android Studio, Gradle, adb, etc.)?
adb instrument
What is the expected output? What do you see instead?
The below error causes the Activity crash.
java.lang.IllegalStateException: #init was called twice in a row. Make sure to call #release after every #init
at android.support.test.espresso.intent.Checks.checkState(Checks.java:75)
at android.support.test.espresso.intent.Intents.internalInit(Intents.java:252)
at android.support.test.espresso.intent.Intents.init(Intents.java:133)
at android.support.test.espresso.intent.rule.IntentsTestRule.afterActivityLaunched(IntentsTestRule.java:59)
at android.support.test.rule.ActivityTestRule.launchActivity(ActivityTestRule.java:308)
The problem is that afterActivityLaunched is invoked 2 times, but afterActivityFinished is not called when activity finishes but until tearDown.
I think the fix is to call afterActivityFinished when activity finishes.