@Test
  public void testGetSecret() {
    addAllTestRecords();
    assertThat(accountDb.getSecret(index("johndoe@gmail.com", null))).isEqualTo(SECRET);
    assertThat(accountDb.getSecret(index("amywinehouse@aol.com", null))).isEqualTo(SECRET2);
    assertThat(accountDb.getSecret(index("everycombo@gmail.com", null))).isEqualTo(SECRET);
    assertThat(accountDb.getSecret(index("Yahoo:everycombo@gmail.com", null))).isEqualTo(SECRET);
    assertThat(accountDb.getSecret(index("everycombo@gmail.com", GOOGLE_ISSUER))).isEqualTo(SECRET);
    assertThat(accountDb.getSecret(index("Yahoo:everycombo@gmail.com", "Yahoo")))
        .isEqualTo(SECRET2);
    // Try a non-existent name
    assertThat(accountDb.getSecret(index("marywinehouse@aol.com", null))).isNull();
  }
A list of {@link TestAccount}s that all have issuers.
javatests/com/google/android/apps/authenticator/otp/AccountDbTest.java