@Test
public void serviceAccountEmailShouldFailIfNotServiceAccount() {

  var credentials = GoogleCredentials.newBuilder().build();
  exception.expect(IllegalArgumentException.class);
  exception.expectMessage("Credential is not a service account");
  ServiceAccounts.serviceAccountEmail(credentials);
}