Robotium を使用して、アプリケーションのテストを自動化しようとしています。テストケースは文書化されており、特定の順序でテストすることになっています。しかし、Junit はテストをアルファベット順に実行しているようです。実行順序を変更するにはどうすればよいですか? 私のテストクラスの基本的な構造は次のとおりです。
public class ETTerminalTest extends ActivityInstrumentationTestCase2<IdleActivity> {
private Solo solo;
private static final Logger LOGGER = LoggerFactory.getLogger(ETTerminalTest.class);
public ETTerminalTest() {
super("com.employtouch.etterminal.ui.activity", IdleActivity.class);
}
protected void setUp() throws Exception {
solo = new Solo(getInstrumentation(), getActivity());
}
@Smoke
public void testEnterPin() throws Exception {
...
}
@Smoke
public void testWhatEver() throws Exception {
...
}
@Smoke
public void testSomethingElse() throws Exception {
...
}
@Override
public void tearDown() throws Exception {
try {
//Robotium will finish all the activities that have been opened
solo.finalize();
} catch (Throwable e) {
e.printStackTrace();
}
getActivity().finish();
super.tearDown();
}
}