HttpRequest httpRequest = new HttpRequest(Uri.parse("http://www.example.org/somecontent"));
httpRequest.setMethod("GET");
httpRequest.setAuthType(AuthType.SIGNED);
expect(pipeline.execute(eqRequest(httpRequest))).andReturn(builder.create()).anyTimes();
replay();
RpcHandler operation = registry.getRpcHandler(request);
try {
operation.execute(emptyFormItems, null, converter).get();
fail("Cannot execute a request without a security token");
} catch (ExecutionException ee) {
assertTrue(ee.getCause() instanceof ProtocolException);
}
verify();