use of com.nike.riposte.server.config.AppInfo in project riposte by Nike-Inc.
the class AwsUtilTest method getAppInfoFutureWithAwsInfo_with_all_args_returns_AppInfoImpl_createLocalInstance_if_environment_is_local_or_compiletimetest.
@DataProvider(value = { "local", "compiletimetest" })
@Test
public void getAppInfoFutureWithAwsInfo_with_all_args_returns_AppInfoImpl_createLocalInstance_if_environment_is_local_or_compiletimetest(String environment) {
// given
String appId = "appid-" + UUID.randomUUID().toString();
AppInfo expectedResult = AppInfoImpl.createLocalInstance(appId);
// when
AppInfo result = AwsUtil.getAppInfoFutureWithAwsInfo(appId, environment, asyncClientMock).join();
// then
assertThat(result.appId()).isEqualTo(expectedResult.appId()).isEqualTo(appId);
assertThat(result.environment()).isEqualTo(expectedResult.environment());
assertThat(result.dataCenter()).isEqualTo(expectedResult.dataCenter());
assertThat(result.instanceId()).isEqualTo(expectedResult.instanceId());
}
Aggregations