LoginInteractor { @NonNull public synchronized Maybe<UserCredentialsPayload> getLastUserCredentialsPayload() { if (userCredentialsPayload != null) { return Maybe.just(userCredentialsPayload); } else { return Maybe.empty(); } } @Inject  LoginInteractor(@NonNull Context context, @NonNull IdentityManagerImpl identityManager); @NonNull synchronized Observable<UiIndicator<String>> loginOrSignUp(@NonNull final UserCredentialsPayload userCredentialsPayload); @NonNull synchronized Maybe<UserCredentialsPayload> getLastUserCredentialsPayload(); synchronized void onLoginResultsConsumed();  }
@Test public void getLastUserCredentialsPayloadDefaultsAsEmpty() { final TestObserver<UserCredentialsPayload> testObserver = interactor.getLastUserCredentialsPayload().test(); testObserver.assertNoValues(); testObserver.assertComplete(); testObserver.assertNoErrors(); }