From b1ba62470798eea432816f80303fba742fffdeab Mon Sep 17 00:00:00 2001 From: Andrei Savu Date: Thu, 15 Mar 2012 14:15:50 +0200 Subject: [PATCH] Only select networks with isDefault(true) for tests --- .../cloudstack/features/VirtualMachineClientLiveTest.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apis/cloudstack/src/test/java/org/jclouds/cloudstack/features/VirtualMachineClientLiveTest.java b/apis/cloudstack/src/test/java/org/jclouds/cloudstack/features/VirtualMachineClientLiveTest.java index 350d5a162e..6b8e7ce3c3 100644 --- a/apis/cloudstack/src/test/java/org/jclouds/cloudstack/features/VirtualMachineClientLiveTest.java +++ b/apis/cloudstack/src/test/java/org/jclouds/cloudstack/features/VirtualMachineClientLiveTest.java @@ -25,6 +25,7 @@ import static com.google.common.collect.Iterables.get; import static com.google.common.collect.Iterables.getFirst; import static com.google.common.collect.Iterables.getOnlyElement; import static com.google.common.collect.Sets.filter; +import static org.jclouds.cloudstack.options.ListNetworksOptions.Builder.isDefault; import static org.testng.Assert.assertEquals; import static org.testng.Assert.assertTrue; @@ -88,7 +89,7 @@ public class VirtualMachineClientLiveTest extends BaseCloudStackClientLiveTest { public static VirtualMachine createVirtualMachine(CloudStackClient client, Long defaultTemplate, RetryablePredicate jobComplete, RetryablePredicate virtualMachineRunning) { - Set networks = client.getNetworkClient().listNetworks(); + Set networks = client.getNetworkClient().listNetworks(isDefault(true)); if (networks.size() > 0) { Network network = get(networks, 0); return createVirtualMachineInNetwork(network,