@Test
public void testRemoteWithTimeOut() throws APIException, CadiException {
when(trans.start("Call AAF Service", Env.REMOTE)).thenReturn(tt);
- when(aafcon.clientAs(Config.AAF_DEFAULT_VERSION, trans.getUserPrincipal())).thenReturn(c);
+ when(aafcon.clientAs(Config.AAF_DEFAULT_API_VERSION, trans.getUserPrincipal())).thenReturn(c);
when(c.read("/authz/perms/user/null?scopes=APPLICATION:HANDLER",
"application/Perms+json;charset=utf-8;version=2.0")).thenReturn(fs);
when(fs.get(0)).thenReturn(true);
@Test
public void testRemoteWith404() throws APIException, CadiException {
when(trans.start("Call AAF Service", Env.REMOTE)).thenReturn(tt);
- when(aafcon.clientAs(Config.AAF_DEFAULT_VERSION, trans.getUserPrincipal())).thenReturn(c);
+ when(aafcon.clientAs(Config.AAF_DEFAULT_API_VERSION, trans.getUserPrincipal())).thenReturn(c);
when(c.read("/authz/perms/user/null?scopes=APPLICATION:HANDLER",
"application/Perms+json;charset=utf-8;version=2.0")).thenReturn(fs);
when(fs.get(0)).thenReturn(false);
@Test
public void testRemote() throws APIException, CadiException {
when(trans.start("Call AAF Service", Env.REMOTE)).thenReturn(tt);
- when(aafcon.clientAs(Config.AAF_DEFAULT_VERSION, trans.getUserPrincipal())).thenReturn(c);
+ when(aafcon.clientAs(Config.AAF_DEFAULT_API_VERSION, trans.getUserPrincipal())).thenReturn(c);
when(c.read("/authz/perms/user/null?scopes=APPLICATION:HANDLER",
"application/Perms+json;charset=utf-8;version=2.0")).thenReturn(fs);
when(fs.get(0)).thenReturn(false);