@Test
public void listSecrets() {

  SanitizedSecret secret1 = SanitizedSecret.of(1, "name1", "desc","checksum", NOW, "user", NOW, "user",
      emptyMap, null, null, 1136214245, 125L, NOW, "user");
  SanitizedSecret secret2 = SanitizedSecret.of(2, "name2", "desc","checksum", NOW, "user", NOW, "user",
      emptyMap, null, null, 1136214245, 250L, NOW, "user");
  when(secretController.getSanitizedSecrets(null, null)).thenReturn(ImmutableList.of(secret1, secret2));
  List<SanitizedSecret> response = resource.listSecrets(user);
  assertThat(response).containsOnly(secret1, secret2);
}