use of org.openstack.keystone.auth.client.KeystoneAuthenticationToken in project platformlayer by platformlayer.
the class SmokeTest method listTenants_forgedToken.
@Test(expected = KeystoneAuthenticationException.class)
public void listTenants_forgedToken() throws Exception {
KeystoneAuthenticationClient client = new KeystoneAuthenticationClient();
KeystoneAuthenticationToken fakeToken = buildFakeToken("HELLOWORLD");
client.listTenants(fakeToken);
}
use of org.openstack.keystone.auth.client.KeystoneAuthenticationToken in project platformlayer by platformlayer.
the class SmokeTest method buildFakeToken.
private KeystoneAuthenticationToken buildFakeToken(String tokenCode) {
Access auth = new Access();
Token tokenObject = new Token();
tokenObject.setId(tokenCode);
auth.setToken(tokenObject);
return new KeystoneAuthenticationToken(auth);
}
Aggregations