Bog*_*iel 21 android android-studio
我不知道如何测试,我正在按照教程.我正在尝试运行:
package name.company.sunshine.app.data;
import android.test.AndroidTestCase;
public class TestPractice extends AndroidTestCase {
/*
This gets run before every test.
*/
@Override
protected void setUp() throws Exception {
super.setUp();
}
public void testThatDemonstratesAssertions() throws Throwable {
int a = 5;
int b = 3;
int c = 5;
int d = 10;
assertEquals("X should be equal", a, c);
assertTrue("Y should be true", d > a);
assertFalse("Z should be false", a == b);
if (b > d) {
fail("XX should never happen");
}
}
@Override
protected void tearDown() throws Exception {
super.tearDown();
}
}
Run Code Online (Sandbox Code Playgroud)
但我在控制台左下角的某个地方Test events were not received
.我究竟做错了什么 ?我应该跑别的吗?
归档时间: |
|
查看次数: |
7735 次 |
最近记录: |