ServerFoundActivity extends BaseActivity implements ServerFoundView { @OnClick(R.id.button_connect) public void onConnectButtonClick(View view) { presenter.onClickAccept(); }  static Intent getCallingIntent(Context context, ServerModel serverModel); @Override boolean onOptionsItemSelected(MenuItem item); @Override void renderServer(@NonNull ServerModel serverModel); @Override void showError(@NonNull String errorMessage); @Override void navigateBack(boolean isSuccess, ServerModel serverModel); @OnClick(R.id.button_connect) void onConnectButtonClick(View view); static final String KEY_SERVER; }
@Test public void shouldNotifyPresenterWhenClickAccept() throws Exception { serverFoundActivity.onConnectButtonClick(null); verify(mockServerFoundPresenter).onClickAccept(); }