@Test
 public void testRoute53Metadata() {
   assertThat(PROVIDER.name()).isEqualTo("route53");
   assertThat(PROVIDER.supportsDuplicateZoneNames()).isTrue();
   assertThat(PROVIDER.credentialTypeToParameterNames())
       .containsEntry("accessKey", Arrays.asList("accessKey", "secretKey"))
       .containsEntry("session", Arrays.asList("accessKey", "secretKey", "sessionToken"));
 }
Beispiel #2
0
    public static String providerAndCredentialsTable() {
      StringBuilder builder = new StringBuilder();

      builder.append(format(table, "provider", "credential type", "credential arguments"));
      for (Provider provider : listProviders()) {
        if (provider.getCredentialTypeToParameterNames().isEmpty())
          builder.append(format("%-20s%n", provider.getName()));
        for (Entry<String, Collection<String>> entry :
            provider.getCredentialTypeToParameterNames().asMap().entrySet()) {
          builder.append(
              format(
                  table,
                  provider.getName(),
                  entry.getKey(),
                  Joiner.on(' ').join(entry.getValue())));
        }
      }
      return builder.toString();
    }