liudonghua123 / android-test-kit

Automatically exported from code.google.com/p/android-test-kit
0 stars 0 forks source link

java.lang.RuntimeException #92

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hello! I've problem, to use this code:

public abstract class BaseTest extends
        ActivityInstrumentationTestCase2<TimelineListActivity> {

    public void setUp() throws Exception {
        super.setUp();
        getActivity();
    }
}

I get sometimes this exception in line getActivity():

java.lang.RuntimeException: Could not launch intent Intent { 
act=android.intent.action.MAIN flg=0x10000000 
cmp=com.kurento.apps.android.hnj.uci.user/.TimelineListActivity } within 45 
seconds. Perhaps the main thread has not gone idle within a reasonable amount 
of time? There could be an animation or something constantly repainting the 
screen. Or the activity is doing network calls on creation? See the threaddump 
logs. For your reference the last time the event queue was idle before your 
activity launch request was 1405412166446 and and now the last time the queue 
went idle was: 1405412211352. If these numbers are the same your activity might 
be hogging the event queue.

I dont know why.

Original issue reported on code.google.com by 1989...@gmail.com on 15 Jul 2014 at 8:28

GoogleCodeExporter commented 9 years ago
Your app is not going idle in 45 seconds. This is going to be a problem for 
both Espresso and your users (e.g. if you have some background animation 
constantly repainting the screen, you app will be draining battery).

Original comment by vale...@google.com on 19 Nov 2014 at 10:26