Project jclouds/jclouds in file ...cloudstack.features.GlobalHostAsyncClientTest.java (2013-01-05)
@@ -18,8 +18,6 @@
  */
 package org.jclouds.cloudstack.features;
 
-import java.lang.reflect.Method;
-
 import org.jclouds.Fallbacks.EmptySetOnNotFoundOr404;
 import org.jclouds.cloudstack.internal.BaseCloudStackAsyncClientTest;
 import org.jclouds.cloudstack.options.ListHostsOptions;
@@ -27,6 +25,9 @@ import org.jclouds.http.HttpRequest;
 import org.jclouds.http.functions.ParseFirstJsonValueNamed;
 import org.testng.annotations.Test;
 
+import com.google.common.collect.ImmutableList;
+import com.google.common.reflect.Invokable;
+
 /**
  * Tests behavior of {@code GlobalHostAsyncClient}
  *
@@ -36,8 +37,8 @@ import org.testng.annotations.Test;
 public class GlobalHostAsyncClientTest extends BaseCloudStackAsyncClientTest<GlobalHostAsyncClient> {
 
    public void testListHosts() throws Exception {
-      Method method =GlobalHostAsyncClient.class.getMethod("listHosts", ListHostsOptions[].class);
-      HttpRequest httpRequest = processor.createRequest(method);
+      Invokable<?, ?> method = Invokable.from(GlobalHostAsyncClient.class.getMethod("listHosts", ListHostsOptions[].class));
+      HttpRequest httpRequest = processor.createRequest(method, ImmutableList.of());
 
       assertRequestLineEquals(httpRequest,
          "GET http://localhost:8080/client/api?response=json&command=listHosts&listAll=true HTTP/1.1");