use of com.yahoo.athenz.zms.SignedDomain in project athenz by yahoo.
the class ZTSImplTest method testGetPublicKey.
@Test
public void testGetPublicKey() {
SignedDomain signedDomain = createSignedDomain("coretech", "weather", "storage", true);
store.processDomain(signedDomain, false);
String pubKey = zts.getPublicKey("coretech", "storage", "0");
assertEquals(pubKey, ZTS_PEM_CERT0);
pubKey = zts.getPublicKey("coretech", "storage", "100");
assertNull(pubKey);
}
use of com.yahoo.athenz.zms.SignedDomain in project athenz by yahoo.
the class InstanceProviderManagerTest method testGetHttpsProviderUnknownProvider.
@Test
public void testGetHttpsProviderUnknownProvider() {
SignedDomain signedDomain = createSignedDomainHttpsEndpoint("coretech", "weather", true, true);
store.processDomain(signedDomain, false);
InstanceProviderManager provider = new InstanceProviderManager(store, null);
InstanceProvider client = provider.getProvider("coretech.weather");
assertNotNull(client);
client.close();
}
use of com.yahoo.athenz.zms.SignedDomain in project athenz by yahoo.
the class InstanceProviderManagerTest method testGetProviderClientInvalidService.
@Test
public void testGetProviderClientInvalidService() {
SignedDomain signedDomain = createSignedDomainHttpsEndpoint("coretech", "weather", true, true);
store.processDomain(signedDomain, false);
InstanceProviderManager provider = new InstanceProviderManager(store, null);
InstanceProvider client = provider.getProvider("coretech.weather2");
assertNull(client);
}
use of com.yahoo.athenz.zms.SignedDomain in project athenz by yahoo.
the class InstanceProviderManagerTest method testGetClassProvider.
@Test
public void testGetClassProvider() {
SignedDomain signedDomain = createSignedDomainClassEndpoint("coretech", "weather", true, true);
store.processDomain(signedDomain, false);
InstanceProviderManager provider = new InstanceProviderManager(store, null);
InstanceProvider client = provider.getProvider("coretech.weather");
assertNotNull(client);
client.close();
}
use of com.yahoo.athenz.zms.SignedDomain in project athenz by yahoo.
the class InstanceProviderManagerTest method testGetProviderClientInvalidDomain.
@Test
public void testGetProviderClientInvalidDomain() {
SignedDomain signedDomain = createSignedDomainHttpsEndpoint("coretech", "weather", true, true);
store.processDomain(signedDomain, false);
InstanceProviderManager provider = new InstanceProviderManager(store, null);
InstanceProvider client = provider.getProvider("coretech2.weather");
assertNull(client);
}
Aggregations