public void testInvokeTarget() throws InvocationTargetException, RMIHostRuntimeException, RMIHostException, IllegalArgumentException,
IllegalAccessException, SecurityException, NoSuchMethodException {
Method method = Object.class.getDeclaredMethod("toString", new Class[] {});
RMIHost host = createMock(RMIHost.class);
expect(host.findService(null, null, null)).andReturn(new Remote() {
});
replay(host);
RMIInvoker invoker = new RMIInvoker(host, null, null, null, method);
assertNotNull(invoker.invokeTarget(new Object[] {}));
}