NullPointer Exception when using Espresso

前端 未结 5 997
孤独总比滥情好
孤独总比滥情好 2021-01-19 16:58

I\'m trying to use Espresso. But I got this error and I have no if I\'m missing some codes.

any thoughts will be highly appreciated.

error log:



        
5条回答
  •  轻奢々
    轻奢々 (楼主)
    2021-01-19 18:00

    You should use GoogleInstrumentationTestRunner, as others mentioned. If you build with ant, You need to add an element to the "project" directive in build.xml of the Test Project like below.

    in build.xml

    
    
        ...
    
       
    
    

提交回复
热议问题