This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class BaseTestClass { | |
@Before | |
public void setup() { | |
ShadowLog.stream = System.out; | |
RxJavaTestPlugins.resetPlugins(); | |
RxJavaTestPlugins.getInstance().registerSchedulersHook(new RxJavaSchedulersHook() { | |
@Override |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class AlertTest { | |
@Test | |
public void check_alert() { | |
AlertDialog alert = ShadowAlertDialog.getLatestAlertDialog(); | |
assertNotNull(alert); | |
ShadowAlertDialog sAlert = Robolectric.shadowOf(alert); | |
assertThat(sAlert.getTitle().toString(), is(Robolectric.application.getString(R.string.adb_warning_title))); | |
} | |
} |
NewerOlder