@Test public void shouldSetMax() { assertThat(dialog.getMax()).isEqualTo(0); dialog.setMax(41); assertThat(dialog.getMax()).isEqualTo(41); }
public void updateProgressDialog(long progress) { if (progress == 100) { progressDialog.setProgress(progressDialog.getMax()); setResult(RESULT_OK, resultIntent); progressDialog.dismiss(); finish(); } else { progressDialog.setProgress((int) progress); } }