@Test void testGetGroupMappingsWhenAdminGroupIsMissing() { assertThrows(CloudbreakServiceException.class, () -> underTest.getGroupMappings(REGION, credential, null)); }
public Map<String, String> getGroupMappings(String region, Credential credential, String adminGroupName) { String accountId = getAccountId(region, credential); if (StringUtils.isNotEmpty(adminGroupName)) { return replaceAccountId(getGroupMappings(adminGroupName), accountId); } else { throw new CloudbreakServiceException(String.format("Failed to get group mappings because of missing adminGroupName for accountId: %s", accountId)); } }
AwsMockAccountMappingService { public Map<String, String> getGroupMappings(String region, Credential credential, String adminGroupName) { String accountId = getAccountId(region, credential); if (StringUtils.isNotEmpty(adminGroupName)) { return replaceAccountId(getGroupMappings(adminGroupName), accountId); } else { throw new CloudbreakServiceException(String.format("Failed to get group mappings because of missing adminGroupName for accountId: %s", accountId)); } } }
AwsMockAccountMappingService { public Map<String, String> getGroupMappings(String region, Credential credential, String adminGroupName) { String accountId = getAccountId(region, credential); if (StringUtils.isNotEmpty(adminGroupName)) { return replaceAccountId(getGroupMappings(adminGroupName), accountId); } else { throw new CloudbreakServiceException(String.format("Failed to get group mappings because of missing adminGroupName for accountId: %s", accountId)); } } AwsMockAccountMappingService(CloudPlatformConnectors cloudPlatformConnectors, CredentialToCloudCredentialConverter credentialConverter); }
AwsMockAccountMappingService { public Map<String, String> getGroupMappings(String region, Credential credential, String adminGroupName) { String accountId = getAccountId(region, credential); if (StringUtils.isNotEmpty(adminGroupName)) { return replaceAccountId(getGroupMappings(adminGroupName), accountId); } else { throw new CloudbreakServiceException(String.format("Failed to get group mappings because of missing adminGroupName for accountId: %s", accountId)); } } AwsMockAccountMappingService(CloudPlatformConnectors cloudPlatformConnectors, CredentialToCloudCredentialConverter credentialConverter); Map<String, String> getGroupMappings(String region, Credential credential, String adminGroupName); Map<String, String> getUserMappings(String region, Credential credential); }
AwsMockAccountMappingService { public Map<String, String> getGroupMappings(String region, Credential credential, String adminGroupName) { String accountId = getAccountId(region, credential); if (StringUtils.isNotEmpty(adminGroupName)) { return replaceAccountId(getGroupMappings(adminGroupName), accountId); } else { throw new CloudbreakServiceException(String.format("Failed to get group mappings because of missing adminGroupName for accountId: %s", accountId)); } } AwsMockAccountMappingService(CloudPlatformConnectors cloudPlatformConnectors, CredentialToCloudCredentialConverter credentialConverter); Map<String, String> getGroupMappings(String region, Credential credential, String adminGroupName); Map<String, String> getUserMappings(String region, Credential credential);  }