use of org.apereo.cas.configuration.model.support.dynamodb.AbstractDynamoDbProperties in project cas by apereo.
the class AmazonClientConfigurationBuilderTests method verifyOperation.
@Test
public void verifyOperation() {
val properties = new AbstractDynamoDbProperties() {
private static final long serialVersionUID = -3599433486448467450L;
};
properties.setLocalAddress("github.com");
properties.setEndpoint("http://localhost:4532");
properties.setProxyHost("http://localhost:8080");
val httpClientBuilder = mock(SampleClientBuilder.class);
val clientBuilder = mock(AwsSyncClientBuilder.class);
when(clientBuilder.httpClientBuilder(any())).thenReturn(httpClientBuilder);
assertDoesNotThrow(() -> AmazonClientConfigurationBuilder.prepareClientBuilder(clientBuilder, StaticCredentialsProvider.create(AwsBasicCredentials.create("key", "secret")), properties));
}
use of org.apereo.cas.configuration.model.support.dynamodb.AbstractDynamoDbProperties in project cas by apereo.
the class AmazonDynamoDbClientFactoryTests method verifyAction.
@Test
public void verifyAction() {
val factory = new AmazonDynamoDbClientFactory();
val properties = new AbstractDynamoDbProperties() {
private static final long serialVersionUID = -3599433486448467450L;
};
properties.setRegion(Region.US_EAST_1.id());
val client = factory.createAmazonDynamoDb(properties);
assertNotNull(client);
}
Aggregations