Espresso test error: AppNotIdleException

前端 未结 4 1504
栀梦
栀梦 2020-12-11 14:32

I turned off all animations on developer options. But I still get this exception when trying to click on one of the buttons.

My app is indeed active and not idle ent

4条回答
  •  没有蜡笔的小新
    2020-12-11 15:17

    you can check this wayes:

    way 1: disable animation in developer options:

    Setting -> developer options -> Window animation scale -> off
    
                                    Transition animation scale -> off
    
                                    Animator duration scale -> off
    

    way 2: if you have customView in build.gradle use this

    defaultConfig {
    
       //...
    
       testOptions {
          animationsDisabled = true
       }
    
    }
    

提交回复
热议问题