この文書の現在のバージョンと選択したバージョンの差分を表示します。
両方とも前のリビジョン 前のリビジョン | |||
junit4 [2015/10/21 18:11] sou [メモ] |
junit4 [2015/12/04 13:16] (現在) sou |
||
---|---|---|---|
ライン 35: | ライン 35: | ||
- setUp() を Override し、public に変更し @Before をつける\\ | - setUp() を Override し、public に変更し @Before をつける\\ | ||
- tearDown() を Override し、public に変更し @After をつける\\ | - tearDown() を Override し、public に変更し @After をつける\\ | ||
- | - 必要に応じて AndroidTestCase.setContext(InstrumentationRegistry.getContext()) や \\InstrumentationTestCase.injectInstrumentation(InstrumentationRegistry.getInstrumentation()) を setUp() で行う\\ | + | - 必要に応じて AndroidTestCase.setContext(InstrumentationRegistry.getContext()) や\\InstrumentationTestCase.injectInstrumentation(InstrumentationRegistry.getInstrumentation()) を setUp() で行う\\ |
- | - メソッド名の命名規則として先頭にtestをつける (例: testHoge())\\ | + | |