@Test public void shouldGoToInitInventoryAfterMethodInvoked() { loginActivity.goToInitInventory(); Intent intent = shadowOf(loginActivity).getNextStartedActivity(); assertThat(intent).isNotNull(); assertThat(intent.getComponent().getClassName()).isEqualTo(InitialInventoryActivity.class.getName()); assertThat(loginActivity.isFinishing()); }
public void goToInitInventory() { if (LMISApp.getInstance().getFeatureToggleFor(R.bool.feature_basic_products_in_inventory)) { startActivity(new Intent(this, BulkInitialInventoryActivity.class)); finish(); } else { launchActivity(InitialInventoryActivity.getIntentToMe(this)); } }
LoginActivity extends BaseActivity implements LoginPresenter.LoginView, View.OnClickListener { public void goToInitInventory() { if (LMISApp.getInstance().getFeatureToggleFor(R.bool.feature_basic_products_in_inventory)) { startActivity(new Intent(this, BulkInitialInventoryActivity.class)); finish(); } else { launchActivity(InitialInventoryActivity.getIntentToMe(this)); } } }
LoginActivity extends BaseActivity implements LoginPresenter.LoginView, View.OnClickListener { public void goToInitInventory() { if (LMISApp.getInstance().getFeatureToggleFor(R.bool.feature_basic_products_in_inventory)) { startActivity(new Intent(this, BulkInitialInventoryActivity.class)); finish(); } else { launchActivity(InitialInventoryActivity.getIntentToMe(this)); } }  }
LoginActivity extends BaseActivity implements LoginPresenter.LoginView, View.OnClickListener { public void goToInitInventory() { if (LMISApp.getInstance().getFeatureToggleFor(R.bool.feature_basic_products_in_inventory)) { startActivity(new Intent(this, BulkInitialInventoryActivity.class)); finish(); } else { launchActivity(InitialInventoryActivity.getIntentToMe(this)); } }  @Override void sendScreenToGoogleAnalyticsAfterLogin(); void goToInitInventory(); void goToHomePage(); void launchActivity(Intent intent); void clearPassword(); void clearErrorAlerts(); @Override boolean needInitInventory(); @Override void showInvalidAlert(); @Override void showPasswordEmpty(); @Override void showUserNameEmpty(); @Override void onClick(View v); @Override void loaded(); @Override void onBackPressed(); void sendSyncStartBroadcast(); void sendSyncFinishedBroadcast(); @Override void sendSyncErrorBroadcast(); }
LoginActivity extends BaseActivity implements LoginPresenter.LoginView, View.OnClickListener { public void goToInitInventory() { if (LMISApp.getInstance().getFeatureToggleFor(R.bool.feature_basic_products_in_inventory)) { startActivity(new Intent(this, BulkInitialInventoryActivity.class)); finish(); } else { launchActivity(InitialInventoryActivity.getIntentToMe(this)); } }  @Override void sendScreenToGoogleAnalyticsAfterLogin(); void goToInitInventory(); void goToHomePage(); void launchActivity(Intent intent); void clearPassword(); void clearErrorAlerts(); @Override boolean needInitInventory(); @Override void showInvalidAlert(); @Override void showPasswordEmpty(); @Override void showUserNameEmpty(); @Override void onClick(View v); @Override void loaded(); @Override void onBackPressed(); void sendSyncStartBroadcast(); void sendSyncFinishedBroadcast(); @Override void sendSyncErrorBroadcast(); @InjectView(R.id.tx_username)
    public EditText etUsername; @InjectView(R.id.tx_password)
    public EditText etPassword; @InjectView(R.id.btn_login)
    public Button btnLogin; @InjectView(R.id.ly_username)
    public TextInputLayout lyUserName; @InjectView(R.id.ly_password)
    public TextInputLayout lyPassword; @InjectView(R.id.iv_visibility_pwd)
    public ImageView ivVisibilityPwd; @InjectView(R.id.iv_logo)
    public ImageView ivLogo; @InjectView(R.id.tv_version)
    public TextView tvVersion; }