PasswordCredentialVersion extends CredentialVersion { @Override public String getCredentialType() { return delegate.getCredentialType(); } PasswordCredentialVersion(final PasswordCredentialVersionData delegate);  PasswordCredentialVersion(final String name);  PasswordCredentialVersion();  PasswordCredentialVersion(
    final StringCredentialValue password,
    final StringGenerationParameters generationParameters,
    final Encryptor encryptor
  ); String getPassword(); void setPasswordAndGenerationParameters(
    final String password,
    final StringGenerationParameters generationParameters
  ); @Override StringGenerationParameters getGenerationParameters(); @Override boolean matchesGenerationParameters(final GenerationParameters generationParameters); @Override String getCredentialType(); @Override void rotate();  }
@Test public void getCredentialType_returnsPassword() { assertThat(subject.getCredentialType(), equalTo("password")); }