@Test
 public void testOnCreate_setsUpProgressBar() {
   ANDROID.assertThat(subject).isNotNull();
   ProgressBar progressBarSpinner = subject.getProgressBarSpinner();
   ANDROID.assertThat(progressBarSpinner).isNotNull();
   int visibility = progressBarSpinner.getVisibility();
   Assertions.assertThat(visibility).isEqualTo(View.VISIBLE);
 }
  @Test
  public void shouldPutRandomNumberInAmountAfterButtonClick() {
    // given
    double value = 100.0;
    given(randomAmount.getAmount()).willReturn(value);
    Button button = ButterKnife.findById(fragment.getView(), R.id.random);

    // when
    button.performClick();

    // then
    EditText amount = ButterKnife.findById(fragment.getView(), R.id.amount);
    ANDROID.assertThat(amount).hasTextString(String.valueOf(value));
  }
 @Test
 public void testOnCreate_setsUpPhotoListView() {
   ANDROID.assertThat(subject.getPhotoRecyclerView()).isNotNull();
 }
예제 #4
0
 public void testInputUriSetAsData() {
   ANDROID.assertThat(builder.getIntent(activity)).hasData("image:input");
 }