2
我編寫了一些測試,並希望獲得IntelliJ Plugin的代碼覆蓋率! 我的測試代碼:Android Studio中的空測試套件運行覆蓋測試
public class TestLogin extends ActivityInstrumentationTestCase2<ActivityAccounting> {
private Solo solo;
public TestLogin() {
super(ActivityAccounting.class);
}
@Override
public void setUp() throws Exception {
super.setUp();
solo = new Solo(this.getInstrumentation(), getActivity());
}
@Test
public void testLoginClick() throws Exception {
//Some UI test
}
}
在EditConfiguration
我添加了一個JUnit測試:
但是,當我與覆蓋我的代碼運行如下錯誤:
什麼我應該怎麼做? tnx提前。
我運行測試添加此依賴關係之前,也是我的測試運行良好,但我無法獲得測試代碼覆蓋率!你有什麼主意嗎? –
您是否將它作爲JUnit測試運行? –
是的。我在EditConfiguration中添加一個名爲「Unnamed」的junit測試,並運行此JUnit測試。 –