Repository: jclouds-labs
Updated Branches:
  refs/heads/master 2b36a75f9 -> 7df28d259


http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/java/org/apache/jclouds/oneandone/rest/internal/BaseOneAndOneApiMockTest.java
----------------------------------------------------------------------
diff --git 
a/oneandone/src/test/java/org/apache/jclouds/oneandone/rest/internal/BaseOneAndOneApiMockTest.java
 
b/oneandone/src/test/java/org/apache/jclouds/oneandone/rest/internal/BaseOneAndOneApiMockTest.java
new file mode 100644
index 0000000..2b04a80
--- /dev/null
+++ 
b/oneandone/src/test/java/org/apache/jclouds/oneandone/rest/internal/BaseOneAndOneApiMockTest.java
@@ -0,0 +1,112 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.jclouds.oneandone.rest.internal;
+
+import com.google.common.base.Charsets;
+import com.google.common.base.Throwables;
+import com.google.common.collect.ImmutableSet;
+import com.google.common.io.Resources;
+import static 
com.google.common.util.concurrent.MoreExecutors.sameThreadExecutor;
+import com.google.gson.JsonParser;
+import com.google.inject.Module;
+import com.squareup.okhttp.mockwebserver.MockWebServer;
+import com.squareup.okhttp.mockwebserver.RecordedRequest;
+import java.io.IOException;
+import java.util.Properties;
+import java.util.Set;
+import org.apache.jclouds.oneandone.rest.OneAndOneApi;
+import org.apache.jclouds.oneandone.rest.OneAndOneProviderMetadata;
+import org.jclouds.ContextBuilder;
+import org.jclouds.concurrent.config.ExecutorServiceModule;
+import org.jclouds.json.Json;
+import org.jclouds.rest.ApiContext;
+import static org.testng.Assert.assertEquals;
+import org.testng.annotations.AfterMethod;
+import org.testng.annotations.BeforeMethod;
+
+public class BaseOneAndOneApiMockTest {
+
+   private static final OneAndOneProviderMetadata METADATA = new 
OneAndOneProviderMetadata();
+   protected static final String AUTH_HEADER = "token";
+   private static final String DEFAULT_ENDPOINT = METADATA.getEndpoint();
+
+   private final Set<Module> modules = ImmutableSet.<Module>of(new 
ExecutorServiceModule(sameThreadExecutor()));
+
+   protected MockWebServer server;
+   protected OneAndOneApi api;
+   private Json json;
+
+   private final JsonParser parser = new JsonParser();
+
+   @BeforeMethod
+   public void start() throws IOException {
+      server = new MockWebServer();
+      server.play();
+      ApiContext<OneAndOneApi> ctx = ContextBuilder.newBuilder("oneandone")
+              .credentials("token", "password")
+              .endpoint(url(""))
+              .modules(modules)
+              .overrides(overrides())
+              .build();
+      json = ctx.utils().injector().getInstance(Json.class);
+      api = ctx.getApi();
+   }
+
+   @AfterMethod(alwaysRun = true)
+   public void stop() throws IOException {
+      server.shutdown();
+      api.close();
+   }
+
+   protected Properties overrides() {
+      return new Properties();
+   }
+
+   protected String url(String path) {
+      return server.getUrl(path).toString();
+   }
+
+   protected String stringFromResource(String resourceName) {
+      try {
+         return Resources.toString(getClass().getResource(resourceName), 
Charsets.UTF_8)
+                 .replace(DEFAULT_ENDPOINT, url(""));
+      } catch (IOException e) {
+         throw Throwables.propagate(e);
+      }
+   }
+
+   protected RecordedRequest assertSent(MockWebServer server, String method, 
String path) throws InterruptedException {
+
+      RecordedRequest request = server.takeRequest();
+
+      assertEquals(request.getMethod(), method);
+      assertEquals(request.getPath(), path);
+      assertEquals(request.getHeader("X-TOKEN"), AUTH_HEADER);
+      return request;
+   }
+
+   protected RecordedRequest assertSent(MockWebServer server, String method, 
String path, String json)
+           throws InterruptedException {
+      RecordedRequest request = assertSent(server, method, path);
+
+      String expectedContentType = "application/json";
+
+      assertEquals(request.getHeader("Content-Type"), expectedContentType);
+      assertEquals(parser.parse(new String(request.getBody(), 
Charsets.UTF_8)), parser.parse(json));
+      return request;
+   }
+}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/java/org/apache/jclouds/oneandone/rest/internal/BaseOneAndOneLiveTest.java
----------------------------------------------------------------------
diff --git 
a/oneandone/src/test/java/org/apache/jclouds/oneandone/rest/internal/BaseOneAndOneLiveTest.java
 
b/oneandone/src/test/java/org/apache/jclouds/oneandone/rest/internal/BaseOneAndOneLiveTest.java
new file mode 100644
index 0000000..7045e45
--- /dev/null
+++ 
b/oneandone/src/test/java/org/apache/jclouds/oneandone/rest/internal/BaseOneAndOneLiveTest.java
@@ -0,0 +1,120 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.jclouds.oneandone.rest.internal;
+
+import com.google.common.base.Predicate;
+import com.google.inject.Injector;
+import com.google.inject.Module;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Properties;
+import java.util.concurrent.TimeUnit;
+import org.apache.jclouds.oneandone.rest.OneAndOneApi;
+import org.apache.jclouds.oneandone.rest.OneAndOneProviderMetadata;
+import org.apache.jclouds.oneandone.rest.config.OneAndOneConstants;
+import org.apache.jclouds.oneandone.rest.config.OneAndOneProperties;
+import org.apache.jclouds.oneandone.rest.domain.Hardware;
+import org.apache.jclouds.oneandone.rest.domain.Hdd;
+import org.apache.jclouds.oneandone.rest.domain.PrivateNetwork;
+import org.apache.jclouds.oneandone.rest.domain.Server;
+import org.apache.jclouds.oneandone.rest.domain.Types;
+import org.apache.jclouds.oneandone.rest.ids.ServerPrivateNetworkRef;
+import org.jclouds.apis.BaseApiLiveTest;
+import org.jclouds.util.Predicates2;
+import static org.testng.Assert.assertTrue;
+
+public class BaseOneAndOneLiveTest extends BaseApiLiveTest<OneAndOneApi> {
+
+   Predicate<Server> waitUntilServerReady;
+   Predicate<ServerPrivateNetworkRef> waitUntilPrivateNetworkReady;
+   private static final OneAndOneProviderMetadata METADATA = new 
OneAndOneProviderMetadata();
+   OneAndOneConstants constants;
+
+   public BaseOneAndOneLiveTest() {
+      provider = "oneandone";
+   }
+
+   @Override
+   protected Properties setupProperties() {
+      Properties props = super.setupProperties();
+      setIfTestSystemPropertyPresent(props, OneAndOneProperties.AUTH_TOKEN);
+      return props;
+   }
+
+   @Override
+   protected OneAndOneApi create(Properties props, Iterable<Module> modules) {
+      Injector injector = 
newBuilder().modules(modules).overrides(props).buildInjector();
+      constants = injector.getInstance(OneAndOneConstants.class);
+      Predicate<Server> serverAvailableCheck = new Predicate<Server>() {
+         @Override
+         public boolean apply(Server currentServer) {
+            Server server = api.serverApi().get(currentServer.id());
+
+            if ((server.status().state() != Types.ServerState.POWERED_OFF
+                    && server.status().state() != Types.ServerState.POWERED_ON)
+                    || server.status().percent() != 0) {
+               return false;
+            } else {
+               return true;
+            }
+         }
+      };
+
+      Predicate<ServerPrivateNetworkRef> privateNetworkAvailableCheck = new 
Predicate<ServerPrivateNetworkRef>() {
+         @Override
+         public boolean apply(ServerPrivateNetworkRef networkRef) {
+            PrivateNetwork server = 
api.serverApi().getPrivateNetwork(networkRef.serverId(), 
networkRef.privateNetworkId());
+            return server.state() != Types.GenericState.ACTIVE;
+         }
+      };
+      waitUntilPrivateNetworkReady = 
Predicates2.retry(privateNetworkAvailableCheck, constants.pollTimeout(), 
constants.pollPeriod(), constants.pollMaxPeriod(), TimeUnit.SECONDS);
+      waitUntilServerReady = Predicates2.retry(serverAvailableCheck, 
constants.pollTimeout(), constants.pollPeriod(), constants.pollMaxPeriod(), 
TimeUnit.SECONDS);
+      return injector.getInstance(OneAndOneApi.class);
+   }
+
+   protected Server createServer(String serverName) {
+
+      List<Hdd.CreateHdd> hdds = new ArrayList<Hdd.CreateHdd>();
+      Hdd.CreateHdd hdd = Hdd.CreateHdd.create(30, Boolean.TRUE);
+      hdds.add(hdd);
+      Hardware.CreateHardware hardware = Hardware.CreateHardware.create(4.0, 
1.0, 2.0, hdds);
+      return api.serverApi().create(Server.CreateServer.builder()
+              .name(serverName)
+              .description("testing with jclouds")
+              .hardware(hardware)
+              .applianceId("81504C620D98BCEBAA5202D145203B4B")
+              .dataCenterId("908DC2072407C94C8054610AD5A53B8C")
+              .password("Test123!")
+              .powerOn(Boolean.TRUE).build());
+   }
+
+   protected void assertNodeAvailable(Server server) {
+      assertTrue(waitUntilServerReady.apply(server), String.format("Server %s 
is not Ready", server));
+   }
+
+   protected void assertPrivateNetworkAvailable(ServerPrivateNetworkRef ref) {
+      assertTrue(waitUntilPrivateNetworkReady.apply(ref), 
String.format("ServerPrivateNetworkRef %s is not Ready", ref));
+   }
+
+   protected Server deleteServer(String serverId) {
+      return api.serverApi().delete(serverId);
+   }
+
+   protected Server turnOnServer(String serverId) {
+      return api.serverApi().updateStatus(serverId, 
Server.UpdateStatus.create(Types.ServerAction.POWER_ON, 
Types.ServerActionMethod.SOFTWARE));
+   }
+}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/add.hdds.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/add.hdds.json 
b/oneandone/src/test/resources/server/add.hdds.json
new file mode 100644
index 0000000..1e96fd5
--- /dev/null
+++ b/oneandone/src/test/resources/server/add.hdds.json
@@ -0,0 +1,54 @@
+{
+  "id": "4B86A3ACC4CEB7A89E012E49FC17F312",
+  "cloudpanel_id": "FE7ED7D",
+  "name": "My Server remame",
+  "description": "My server rename description",
+  "datacenter": {
+    "id": "D0F6D8C8ED29D3036F94C27BBB7BAD36",
+    "location": "USA",
+    "country_code": "US"
+  },
+  "creation_date": "2015-05-07T08:25:37+00:00",
+  "first_password": "Nm4gP97xSw",
+  "status": {
+    "state": "CONFIGURING",
+    "percent": 10
+  },
+  "hardware": {
+    "fixed_instance_size_id": 0,
+    "vcore": 2,
+    "cores_per_processor": 1,
+    "ram": 2,
+    "hdds": [
+    {
+      "id": "0DDE06DFA47743DF928E76AE7DC195C1",
+      "size": 40,
+      "is_main": true
+    },
+    {
+      "id": "B6DAEB7FA4D0CABFD8FE878EC467CA7E",
+      "size": 20,
+      "is_main": false
+    }
+    ]
+  },
+  "image": {
+    "id": "07C170D67C8EC776933FCFF1C299C1C5",
+    "name": "w2012r2datacenter64min"
+  },
+  "dvd": null,
+  "snapshot": null,
+  "ips": [
+  {
+    "id": "D609028BC090EE05665072C721EA4A7A",
+    "ip": "10.4.141.43",
+    "type": "IPV4",
+    "reverse_dns": null,
+    "firewall_policy": null,
+    "load_balancers": []
+  }
+  ],
+  "alerts": [],
+  "monitoring_policy": null,
+  "private_networks": null
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/delete.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/delete.json 
b/oneandone/src/test/resources/server/delete.json
new file mode 100644
index 0000000..c29f865
--- /dev/null
+++ b/oneandone/src/test/resources/server/delete.json
@@ -0,0 +1,51 @@
+{
+    "id": "D2522497990A9FDCB26CE579524E4024",
+    "cloudpanel_id": "01CFD25",
+    "name": "Updatedjava",
+    "description": "Updated desc",
+    "datacenter": {
+        "id": "908DC2072407C94C8054610AD5A53B8C",
+        "country_code": "US",
+        "location": "United States of America"
+    },
+    "creation_date": "2016-05-18T20:42:44+00:00",
+    "first_password": null,
+    "status": {
+        "state": "REMOVING",
+        "percent": 0
+    },
+    "hardware": {
+        "fixed_instance_size_id": null,
+        "vcore": 4,
+        "cores_per_processor": 2,
+        "ram": 4,
+        "hdds": [{
+                "id": "7840E7C4DFF5972625720E297AAF870E",
+                "size": 30,
+                "is_main": true
+            }]
+    },
+    "image": {
+        "id": "81504C620D98BCEBAA5202D145203B4B",
+        "name": "w2012r2datacenter64iso"
+    },
+    "dvd": {
+        "id": "81504C620D98BCEBAA5202D145203B4B",
+        "name": "w2012r2datacenter64iso"
+    },
+    "snapshot": null,
+    "ips": [{
+            "id": "8C4F2B7115EB90C585EE6FFB6A5904A8",
+            "ip": "70.35.203.100",
+            "type": "IPV4",
+            "reverse_dns": null,
+            "firewall_policy": {
+                "id": "34A7E423DA3253E6D38563ED06F1041F",
+                "name": "Linux"
+            },
+            "load_balancers": []
+        }],
+    "alerts": [],
+    "monitoring_policy": null,
+    "private_networks": null
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/get.dvd.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/get.dvd.json 
b/oneandone/src/test/resources/server/get.dvd.json
new file mode 100644
index 0000000..58f3fa4
--- /dev/null
+++ b/oneandone/src/test/resources/server/get.dvd.json
@@ -0,0 +1,4 @@
+{
+  "id": "B77E19E062D5818532EFF11C747BD104",    
+  "name": "Windows 2012 - 64 bits" 
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/get.flavour.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/get.flavour.json 
b/oneandone/src/test/resources/server/get.flavour.json
new file mode 100644
index 0000000..e7c7128
--- /dev/null
+++ b/oneandone/src/test/resources/server/get.flavour.json
@@ -0,0 +1,15 @@
+{
+    "id": "65929629F35BBFBA63022008F773F3EB",
+    "name": "M",
+    "hardware": {
+        "vcore": 1,
+        "cores_per_processor": 1,
+        "ram": 1,
+        "unit": "GB",
+        "hdds": [{
+                "size": 40,
+                "unit": "GB",
+                "is_main": true
+            }]
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/get.hardware.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/get.hardware.json 
b/oneandone/src/test/resources/server/get.hardware.json
new file mode 100644
index 0000000..21d92ba
--- /dev/null
+++ b/oneandone/src/test/resources/server/get.hardware.json
@@ -0,0 +1,13 @@
+{
+    "fixed_instance_size_id": 0,
+    "vcore": 1,
+    "cores_per_processor": 1,
+    "ram": 2,
+    "hdds": [
+        {
+            "id": "8C626C1A7005D0D1F527143C413D461E",
+            "size": 40,
+            "is_main": true
+        }
+    ]
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/get.hdd.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/get.hdd.json 
b/oneandone/src/test/resources/server/get.hdd.json
new file mode 100644
index 0000000..82732d8
--- /dev/null
+++ b/oneandone/src/test/resources/server/get.hdd.json
@@ -0,0 +1,5 @@
+{
+  "id": "1964560F458D95DE1884E443B00E33E7",
+  "size": 40,
+  "is_main": true
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/get.image.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/get.image.json 
b/oneandone/src/test/resources/server/get.image.json
new file mode 100644
index 0000000..9fbc001
--- /dev/null
+++ b/oneandone/src/test/resources/server/get.image.json
@@ -0,0 +1,4 @@
+{
+    "id": "76EBF29C1250167C8754B2B3D1C05F68",
+    "name": "centos7-64std"
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/get.ip.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/get.ip.json 
b/oneandone/src/test/resources/server/get.ip.json
new file mode 100644
index 0000000..2003c20
--- /dev/null
+++ b/oneandone/src/test/resources/server/get.ip.json
@@ -0,0 +1,8 @@
+{
+    "id": "01D4A802798AB77AA72DA2D05E1379E1",
+    "ip": "10.5.135.140",
+    "type": "IPV4",
+    "reverse_dns": null,
+    "firewall_policy": null,
+    "load_balancers": []
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/get.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/get.json 
b/oneandone/src/test/resources/server/get.json
new file mode 100644
index 0000000..0251576
--- /dev/null
+++ b/oneandone/src/test/resources/server/get.json
@@ -0,0 +1,48 @@
+{
+    "id": "C68F3BB07BCBE6191F0ACE996AE4F4F5",
+    "cloudpanel_id": "14DD4DD",
+    "name": "Docs\/Content Test Server: CentOS 7",
+    "description": "",
+    "datacenter": {
+        "id": "908DC2072407C94C8054610AD5A53B8C",
+        "country_code": "US",
+        "location": "United States of America"
+    },
+    "creation_date": "2016-05-05T08:51:48+00:00",
+    "first_password": "Wb3MvEJHOv",
+    "status": {
+        "state": "POWERED_ON",
+        "percent": null
+    },
+    "hardware": {
+        "fixed_instance_size_id": "3D4C49EAEDD42FBC23DB58FE3DEF464F",
+        "vcore": 1,
+        "cores_per_processor": 1,
+        "ram": 0.5,
+        "hdds": [{
+                "id": "DD4587ABB3433F93F895638054899F91",
+                "size": 30,
+                "is_main": true
+            }]
+    },
+    "image": {
+        "id": "B5F778B85C041347BCDCFC3172AB3F3C",
+        "name": "centos7-64std"
+    },
+    "dvd": null,
+    "snapshot": null,
+    "ips": [{
+            "id": "5B0BB42CBAF62A454B25D21545CD9ACD",
+            "ip": "70.35.199.18",
+            "type": "IPV4",
+            "reverse_dns": null,
+            "firewall_policy": null,
+            "load_balancers": [{
+                    "id": "13C3F75BA55AF28B8B2B4E508786F48B",
+                    "name": "My Load Balancer 1"
+                }]
+        }],
+    "alerts": [],
+    "monitoring_policy": null,
+    "private_networks": null
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/get.privatenetwork.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/get.privatenetwork.json 
b/oneandone/src/test/resources/server/get.privatenetwork.json
new file mode 100644
index 0000000..2d20624
--- /dev/null
+++ b/oneandone/src/test/resources/server/get.privatenetwork.json
@@ -0,0 +1,20 @@
+{
+    "id": "40D2C8D5029BF03F7C9D02D54C9F237D",
+    "name": "puppetnet",
+    "description": null,
+    "network_address": "192.168.45.0",
+    "subnet_mask": "255.255.255.0",
+    "state": "CONFIGURING",
+    "datacenter": {
+        "id": "908DC2072407C94C8054610AD5A53B8C",
+        "country_code": "US",
+        "location": "United States of America"
+    },
+    "creation_date": "2016-05-09T13:21:43+00:00",
+    "servers": [{
+            "id": "56EAA98A07C3D1ECE4C3F352938853B4",
+            "name": "jclouds operations test",
+            "lock": 6
+        }],
+    "cloudpanel_id": "pnFF88C_2"
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/get.status.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/get.status.json 
b/oneandone/src/test/resources/server/get.status.json
new file mode 100644
index 0000000..d6bcd9a
--- /dev/null
+++ b/oneandone/src/test/resources/server/get.status.json
@@ -0,0 +1,4 @@
+{
+    "state": "POWERED_ON",
+    "percent": null
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/list.flavours.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/list.flavours.json 
b/oneandone/src/test/resources/server/list.flavours.json
new file mode 100644
index 0000000..51b4b63
--- /dev/null
+++ b/oneandone/src/test/resources/server/list.flavours.json
@@ -0,0 +1,113 @@
+[{
+        "id": "65929629F35BBFBA63022008F773F3EB",
+        "name": "M",
+        "hardware": {
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "unit": "GB",
+            "hdds": [{
+                    "size": 40,
+                    "unit": "GB",
+                    "is_main": true
+                }]
+        }
+    }, {
+        "id": "591A7FEF641A98B38D1C4F7C99910121",
+        "name": "L",
+        "hardware": {
+            "vcore": 2,
+            "cores_per_processor": 1,
+            "ram": 2,
+            "unit": "GB",
+            "hdds": [{
+                    "size": 80,
+                    "unit": "GB",
+                    "is_main": true
+                }]
+        }
+    }, {
+        "id": "E903FA4F907B5AAF17A7E987FFCDCC6B",
+        "name": "XL",
+        "hardware": {
+            "vcore": 2,
+            "cores_per_processor": 1,
+            "ram": 4,
+            "unit": "GB",
+            "hdds": [{
+                    "size": 120,
+                    "unit": "GB",
+                    "is_main": true
+                }]
+        }
+    }, {
+        "id": "57862AE452473D551B1673938DD3DFFE",
+        "name": "XXL",
+        "hardware": {
+            "vcore": 4,
+            "cores_per_processor": 1,
+            "ram": 8,
+            "unit": "GB",
+            "hdds": [{
+                    "size": 160,
+                    "unit": "GB",
+                    "is_main": true
+                }]
+        }
+    }, {
+        "id": "3D4C49EAEDD42FBC23DB58FE3DEF464F",
+        "name": "S",
+        "hardware": {
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 0.5,
+            "unit": "GB",
+            "hdds": [{
+                    "size": 30,
+                    "unit": "GB",
+                    "is_main": true
+                }]
+        }
+    }, {
+        "id": "6A2383038420110058C77057D261A07C",
+        "name": "3XL",
+        "hardware": {
+            "vcore": 8,
+            "cores_per_processor": 1,
+            "ram": 16,
+            "unit": "GB",
+            "hdds": [{
+                    "size": 240,
+                    "unit": "GB",
+                    "is_main": true
+                }]
+        }
+    }, {
+        "id": "EED49B709368C3715382730A604E9F6A",
+        "name": "4XL",
+        "hardware": {
+            "vcore": 12,
+            "cores_per_processor": 1,
+            "ram": 32,
+            "unit": "GB",
+            "hdds": [{
+                    "size": 360,
+                    "unit": "GB",
+                    "is_main": true
+                }]
+        }
+    }, {
+        "id": "EE48ACD55FEFE57E2651862A348D1254",
+        "name": "5XL",
+        "hardware": {
+            "vcore": 16,
+            "cores_per_processor": 1,
+            "ram": 48,
+            "unit": "GB",
+            "hdds": [{
+                    "size": 500,
+                    "unit": "GB",
+                    "is_main": true
+                }]
+        }
+    }]
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/list.hardware.hdds.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/list.hardware.hdds.json 
b/oneandone/src/test/resources/server/list.hardware.hdds.json
new file mode 100644
index 0000000..059ab6b
--- /dev/null
+++ b/oneandone/src/test/resources/server/list.hardware.hdds.json
@@ -0,0 +1,7 @@
+[
+    {
+        "id": "1964560F458D95DE1884E443B00E33E7",
+        "size": 40,
+        "is_main": true
+    }
+]
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/list.ip.firewallPolicies.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/list.ip.firewallPolicies.json 
b/oneandone/src/test/resources/server/list.ip.firewallPolicies.json
new file mode 100644
index 0000000..bbeedf5
--- /dev/null
+++ b/oneandone/src/test/resources/server/list.ip.firewallPolicies.json
@@ -0,0 +1,8 @@
+[{
+        "id": "3C4F21EDFEEDD6ABB728EA5CE684E1AF",
+        "name": "Windows"
+    }, {
+        "id": "3C4F21EDFEEDD6ABB728EA5CE684E1AF",
+        "name": "Windows"
+    }
+]
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/list.ip.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/list.ip.json 
b/oneandone/src/test/resources/server/list.ip.json
new file mode 100644
index 0000000..f5eee49
--- /dev/null
+++ b/oneandone/src/test/resources/server/list.ip.json
@@ -0,0 +1,10 @@
+[
+    {
+        "id": "01D4A802798AB77AA72DA2D05E1379E1",
+        "ip": "10.5.135.140",
+        "type": "IPV4",
+        "reverse_dns": null,
+        "firewall_policy": null,
+        "load_balancers": []
+    }
+]
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/list.ip.loadBalancers.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/list.ip.loadBalancers.json 
b/oneandone/src/test/resources/server/list.ip.loadBalancers.json
new file mode 100644
index 0000000..68354ba
--- /dev/null
+++ b/oneandone/src/test/resources/server/list.ip.loadBalancers.json
@@ -0,0 +1,6 @@
+[
+    {
+        "id": "37E2FDEB2945990CEE4B7927FB1ED425",
+        "name": "My load balancer"
+    }
+]
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/list.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/list.json 
b/oneandone/src/test/resources/server/list.json
new file mode 100644
index 0000000..f1d3495
--- /dev/null
+++ b/oneandone/src/test/resources/server/list.json
@@ -0,0 +1,341 @@
+[{
+        "id": "C68F3BB07BCBE6191F0ACE996AE4F4F5",
+        "name": "Docs\/Content Test Server: CentOS 7",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-05-05T08:51:48+00:00",
+        "image": {
+            "id": "B5F778B85C041347BCDCFC3172AB3F3C",
+            "name": "centos7-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "3D4C49EAEDD42FBC23DB58FE3DEF464F",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 0.5,
+            "hdds": [{
+                    "id": "DD4587ABB3433F93F895638054899F91",
+                    "size": 30,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "5B0BB42CBAF62A454B25D21545CD9ACD",
+                "ip": "70.35.199.18"
+            }],
+        "alerts": null
+    }, {
+        "id": "C547B6BFF993428B72448330883B9A9F",
+        "name": "Doc\/Content Test Server: Ubuntu 14.04",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-03-04T22:05:03+00:00",
+        "image": {
+            "id": "72A90ECC29F718404AC3093A3D78327C",
+            "name": "ubuntu1404-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "0BAE1AF79A047D0E903012298142AFD8",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "8F6D690623443F28E91C770F4D2D2727",
+                "ip": "70.35.202.196"
+            }],
+        "alerts": null
+    }, {
+        "id": "E7D36EC025C73796035BF4F171379025",
+        "name": "Docs\/Content Test Server: CentOS 7 (2)",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-05-05T17:39:50+00:00",
+        "image": {
+            "id": "B5F778B85C041347BCDCFC3172AB3F3C",
+            "name": "centos7-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "F841D521B453B539314D54323AFA6B48",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "FDBE99EDD57F8596CBF71B6B64BD0A92",
+                "ip": "62.151.179.99"
+            }],
+        "alerts": null
+    }, {
+        "id": "4ADC7A1550FBF4F9A75E16D1BF483273",
+        "name": "Docs\/Content Test Server: Win 2012",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-02-25T20:17:49+00:00",
+        "image": {
+            "id": "540D1FA7A714715FC4F0C8558580D2C1",
+            "name": "w2012r2datacenter64std+SQL2012express+Plesk12unlimited"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "591A7FEF641A98B38D1C4F7C99910121",
+            "vcore": 2,
+            "cores_per_processor": 1,
+            "ram": 2,
+            "hdds": [{
+                    "id": "DF5BBF27FC71462FFDD347BAB331A58C",
+                    "size": 80,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "9C44C6E37937F4C7F0877B45D032D4C6",
+                "ip": "70.35.203.229"
+            }],
+        "alerts": null
+    }, {
+        "id": "DDDC4CCA34AAB08132FA1E40F9FEAC25",
+        "name": "App Dev Server 5",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-03-04T21:29:00+00:00",
+        "image": {
+            "id": "96D5CEB497043FD54E834DEC4B8FF70A",
+            "name": "centos7-64cpanel"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "5E23F849DD3D6A47615D8EE441FE74CC",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "E193E9D2213088B3CCE8AD69646CEF18",
+                "ip": "70.35.206.196"
+            }],
+        "alerts": null
+    }, {
+        "id": "8122D014AE7E8B4E5D9337C215F48A19",
+        "name": "Doc\/Content Test Server: Debian 7",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-03-10T21:17:38+00:00",
+        "image": {
+            "id": "D04943D702F82A1FC29B42FD635ACB51",
+            "name": "debian7-64std+Plesk12.5unlimited"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "AC8FEF977EEC56F63C84E78176BD5051",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "D7D42B5E81F649F83AFAF250317A8F64",
+                "ip": "70.35.203.151"
+            }],
+        "alerts": null
+    }, {
+        "id": "BFA8EBD2BE60D224FA87D9AD952C0E1F",
+        "name": "Docs\/Content Test Server: CentOS 6 (2)",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-05-16T21:29:08+00:00",
+        "image": {
+            "id": "C598EAD5691CDADD1501A2AF29A2E91C",
+            "name": "centos6-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "591A7FEF641A98B38D1C4F7C99910121",
+            "vcore": 2,
+            "cores_per_processor": 1,
+            "ram": 2,
+            "hdds": [{
+                    "id": "C59751A93DB3D41230379292D7977B1F",
+                    "size": 80,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "39158AED402DB608969D9B4F6D7BAC13",
+                "ip": "70.35.198.225"
+            }],
+        "alerts": null
+    }, {
+        "id": "55561BAF1FAFBD65600C61D1008C1AC7",
+        "name": "Doc\/Content Test Server: Ubuntu 12.04",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-04-15T18:23:49+00:00",
+        "image": {
+            "id": "84E3B902821F911BE6B43FA36ADA8199",
+            "name": "ubuntu1204-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "84ACD1CD506439F051A163209967EDAE",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "734AACB346D6443BDFF3826E720C995F",
+                "ip": "62.151.176.181"
+            }],
+        "alerts": null
+    }, {
+        "id": "79DF0AD5F3B3EC37E9E0B16806081C13",
+        "name": "Doc\/Content Test Server 2: Ubuntu 14.04",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-03-22T20:50:23+00:00",
+        "image": {
+            "id": "72A90ECC29F718404AC3093A3D78327C",
+            "name": "ubuntu1404-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "8B9685555516904EF13D41B76FDBD602",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "A7E78CC8584D515D0F2F82DCA26701F5",
+                "ip": "62.151.180.105"
+            }],
+        "alerts": null
+    }, {
+        "id": "B7860D2E2015AFFD633435C7A2A7AC28",
+        "name": "testin",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-05-15T22:42:21+00:00",
+        "image": {
+            "id": "72A90ECC29F718404AC3093A3D78327C",
+            "name": "ubuntu1404-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "5B99E4AF5E20106A8226356B1C36ACB6",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "924B7E76DEF6EFB47D6C416E4BF62013",
+                "ip": "70.35.207.184"
+            }],
+        "alerts": null
+    }]
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/list.options-query-test.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/list.options-query-test.json 
b/oneandone/src/test/resources/server/list.options-query-test.json
new file mode 100644
index 0000000..f613fad
--- /dev/null
+++ b/oneandone/src/test/resources/server/list.options-query-test.json
@@ -0,0 +1,309 @@
+
+[{
+        "id": "C68F3BB07BCBE6191F0ACE996AE4F4F5",
+        "name": "Docs\/Content Test Server: CentOS 7",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-05-05T08:51:48+00:00",
+        "image": {
+            "id": "B5F778B85C041347BCDCFC3172AB3F3C",
+            "name": "centos7-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "3D4C49EAEDD42FBC23DB58FE3DEF464F",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 0.5,
+            "hdds": [{
+                    "id": "DD4587ABB3433F93F895638054899F91",
+                    "size": 30,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "5B0BB42CBAF62A454B25D21545CD9ACD",
+                "ip": "70.35.199.18"
+            }],
+        "alerts": null
+    }, {
+        "id": "C547B6BFF993428B72448330883B9A9F",
+        "name": "Doc\/Content Test Server: Ubuntu 14.04",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-03-04T22:05:03+00:00",
+        "image": {
+            "id": "72A90ECC29F718404AC3093A3D78327C",
+            "name": "ubuntu1404-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "0BAE1AF79A047D0E903012298142AFD8",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "8F6D690623443F28E91C770F4D2D2727",
+                "ip": "70.35.202.196"
+            }],
+        "alerts": null
+    }, {
+        "id": "E7D36EC025C73796035BF4F171379025",
+        "name": "Docs\/Content Test Server: CentOS 7 (2)",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-05-05T17:39:50+00:00",
+        "image": {
+            "id": "B5F778B85C041347BCDCFC3172AB3F3C",
+            "name": "centos7-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "F841D521B453B539314D54323AFA6B48",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "FDBE99EDD57F8596CBF71B6B64BD0A92",
+                "ip": "62.151.179.99"
+            }],
+        "alerts": null
+    }, {
+        "id": "4ADC7A1550FBF4F9A75E16D1BF483273",
+        "name": "Docs\/Content Test Server: Win 2012",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-02-25T20:17:49+00:00",
+        "image": {
+            "id": "540D1FA7A714715FC4F0C8558580D2C1",
+            "name": "w2012r2datacenter64std+SQL2012express+Plesk12unlimited"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "591A7FEF641A98B38D1C4F7C99910121",
+            "vcore": 2,
+            "cores_per_processor": 1,
+            "ram": 2,
+            "hdds": [{
+                    "id": "DF5BBF27FC71462FFDD347BAB331A58C",
+                    "size": 80,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "9C44C6E37937F4C7F0877B45D032D4C6",
+                "ip": "70.35.203.229"
+            }],
+        "alerts": null
+    }, {
+        "id": "8122D014AE7E8B4E5D9337C215F48A19",
+        "name": "Doc\/Content Test Server: Debian 7",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-03-10T21:17:38+00:00",
+        "image": {
+            "id": "D04943D702F82A1FC29B42FD635ACB51",
+            "name": "debian7-64std+Plesk12.5unlimited"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "AC8FEF977EEC56F63C84E78176BD5051",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "D7D42B5E81F649F83AFAF250317A8F64",
+                "ip": "70.35.203.151"
+            }],
+        "alerts": null
+    }, {
+        "id": "BFA8EBD2BE60D224FA87D9AD952C0E1F",
+        "name": "Docs\/Content Test Server: CentOS 6 (2)",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-05-16T21:29:08+00:00",
+        "image": {
+            "id": "C598EAD5691CDADD1501A2AF29A2E91C",
+            "name": "centos6-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "591A7FEF641A98B38D1C4F7C99910121",
+            "vcore": 2,
+            "cores_per_processor": 1,
+            "ram": 2,
+            "hdds": [{
+                    "id": "C59751A93DB3D41230379292D7977B1F",
+                    "size": 80,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "39158AED402DB608969D9B4F6D7BAC13",
+                "ip": "70.35.198.225"
+            }],
+        "alerts": null
+    }, {
+        "id": "55561BAF1FAFBD65600C61D1008C1AC7",
+        "name": "Doc\/Content Test Server: Ubuntu 12.04",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-04-15T18:23:49+00:00",
+        "image": {
+            "id": "84E3B902821F911BE6B43FA36ADA8199",
+            "name": "ubuntu1204-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "84ACD1CD506439F051A163209967EDAE",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "734AACB346D6443BDFF3826E720C995F",
+                "ip": "62.151.176.181"
+            }],
+        "alerts": null
+    }, {
+        "id": "79DF0AD5F3B3EC37E9E0B16806081C13",
+        "name": "Doc\/Content Test Server 2: Ubuntu 14.04",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-03-22T20:50:23+00:00",
+        "image": {
+            "id": "72A90ECC29F718404AC3093A3D78327C",
+            "name": "ubuntu1404-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "8B9685555516904EF13D41B76FDBD602",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "A7E78CC8584D515D0F2F82DCA26701F5",
+                "ip": "62.151.180.105"
+            }],
+        "alerts": null
+    }, {
+        "id": "B7860D2E2015AFFD633435C7A2A7AC28",
+        "name": "testin",
+        "description": "",
+        "status": {
+            "state": "POWERED_ON",
+            "percent": null
+        },
+        "datacenter": {
+            "id": "908DC2072407C94C8054610AD5A53B8C",
+            "country_code": "US",
+            "location": "United States of America"
+        },
+        "creation_date": "2016-05-15T22:42:21+00:00",
+        "image": {
+            "id": "72A90ECC29F718404AC3093A3D78327C",
+            "name": "ubuntu1404-64std"
+        },
+        "hardware": {
+            "fixed_instance_size_id": "65929629F35BBFBA63022008F773F3EB",
+            "vcore": 1,
+            "cores_per_processor": 1,
+            "ram": 1,
+            "hdds": [{
+                    "id": "5B99E4AF5E20106A8226356B1C36ACB6",
+                    "size": 40,
+                    "is_main": true
+                }]
+        },
+        "ips": [{
+                "id": "924B7E76DEF6EFB47D6C416E4BF62013",
+                "ip": "70.35.207.184"
+            }],
+        "alerts": null
+    }]
+

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/list.privatenetwork.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/list.privatenetwork.json 
b/oneandone/src/test/resources/server/list.privatenetwork.json
new file mode 100644
index 0000000..8e70dca
--- /dev/null
+++ b/oneandone/src/test/resources/server/list.privatenetwork.json
@@ -0,0 +1,6 @@
+[
+    {
+        "id": "6B7051F17199EF9EA994CD3E4AA450E6",
+        "name": "New private network 1"
+    }
+]
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/list.snapshot.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/list.snapshot.json 
b/oneandone/src/test/resources/server/list.snapshot.json
new file mode 100644
index 0000000..04a8863
--- /dev/null
+++ b/oneandone/src/test/resources/server/list.snapshot.json
@@ -0,0 +1,7 @@
+[
+    {
+        "id": "B77E19E062D5818532EFF11C747BD104",
+        "creation_date": "2015-04-06T23:48:38Z",
+        "deletion_date": "2015-04-09T23:48:38Z"
+    }
+]
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/update.image.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/update.image.json 
b/oneandone/src/test/resources/server/update.image.json
new file mode 100644
index 0000000..9e55fd1
--- /dev/null
+++ b/oneandone/src/test/resources/server/update.image.json
@@ -0,0 +1,73 @@
+{
+    "id": "B2C48C21526E16E3FAF59ACD083DC470",
+    "name": "690929B",
+    "public_name": "java test fixed instance 1",
+    "description": "testing with jclouds",
+    "state_id": 0,
+    "state": "DEPLOYING",
+    "vcpu": 2,
+    "cores_per_processor": 1,
+    "ram": 2,
+    "appliance_id": "7C5FA1D21B98DE39D7516333AAB7DA54",
+    "appliance_name": "w2012r2datacenter64std+SQL2012express",
+    "os_name": "Windows2012R2",
+    "dvd_appliance_id": null,
+    "datacenter_id": "908DC2072407C94C8054610AD5A53B8C",
+    "lock_for_action": null,
+    "configuration_id": "591A7FEF641A98B38D1C4F7C99910121",
+    "configuration_name": "VPS_L",
+    "snapshot_id": null,
+    "start_date": "2016-06-26T15:43:43+00:00",
+    "hdds": [{
+            "id": "B6A5488F233BCE8BFA6B7B48886EA025",
+            "technical_id": 2000,
+            "size": 80,
+            "type_id": 1,
+            "is_main": true,
+            "vm_id": "B2C48C21526E16E3FAF59ACD083DC470"
+        }],
+    "hdd": 80,
+    "ips": ["50.21.182.115"],
+    "hw_version": null,
+    "first_password": null,
+    "rsa_key": 0,
+    "alerts": [],
+    "alerts_count": [],
+    "resize_limits": {
+        "vcpu_min": 2,
+        "vcpu_max": "16.00",
+        "vcpu_step": 1,
+        "ram_min": 2,
+        "ram_max": 32,
+        "ram_step": "0.50",
+        "vcpu_restrictions": 
["RESIZE_RESTRICTION_HOT_VCPU_DECREASE_NOT_ALLOWED"],
+        "ram_restrictions": 
["RESIZE_RESTRICTION_HOT_RAM_DECREASE_NOT_ALLOWED", 
"RESIZE_RESTRICTION_HOT_RAM_X16"],
+        "hdd_restrictions": ["RESIZE_RESTRICTION_APPLIANCE_MINIMUM_HDD_SIZE"],
+        "hdd_min": 80,
+        "hdd_max": "500.00",
+        "hdd_step": "10.00"
+    },
+    "monitoring_policy": [],
+    "licenses": [{
+            "name": "Windows_2012_Datacenter",
+            "activation_code": "",
+            "resource": "ngcs.licenses.win"
+        }],
+    "private_networks": [],
+    "vmware_tools_state_id": 11,
+    "last_logs": [{
+            "id": "2F7707D35651A70BA7A64B8332D26713",
+            "date": "2016-06-26T15:49:53+00:00",
+            "action": "REINSTALL",
+            "time": 2,
+            "result": "CONFIGURING",
+            "type": "VM"
+        }, {
+            "id": "D244452F7CAC82B82A74484007F17617",
+            "date": "2016-06-26T15:43:43+00:00",
+            "action": "CREATEVM",
+            "time": 261,
+            "result": "OK",
+            "type": "VM"
+        }]
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/oneandone/src/test/resources/server/update.json
----------------------------------------------------------------------
diff --git a/oneandone/src/test/resources/server/update.json 
b/oneandone/src/test/resources/server/update.json
new file mode 100644
index 0000000..7f8f93f
--- /dev/null
+++ b/oneandone/src/test/resources/server/update.json
@@ -0,0 +1,51 @@
+{
+    "id": "D2522497990A9FDCB26CE579524E4024",
+    "cloudpanel_id": "01CFD25",
+    "name": "Updatedjava",
+    "description": "Updated desc",
+    "datacenter": {
+        "id": "908DC2072407C94C8054610AD5A53B8C",
+        "country_code": "US",
+        "location": "United States of America"
+    },
+    "creation_date": "2016-05-18T20:42:44+00:00",
+    "first_password": null,
+    "status": {
+        "state": "POWERED_ON",
+        "percent": null
+    },
+    "hardware": {
+        "fixed_instance_size_id": null,
+        "vcore": 4,
+        "cores_per_processor": 2,
+        "ram": 4,
+        "hdds": [{
+                "id": "7840E7C4DFF5972625720E297AAF870E",
+                "size": 30,
+                "is_main": true
+            }]
+    },
+    "image": {
+        "id": "81504C620D98BCEBAA5202D145203B4B",
+        "name": "w2012r2datacenter64iso"
+    },
+    "dvd": {
+        "id": "81504C620D98BCEBAA5202D145203B4B",
+        "name": "w2012r2datacenter64iso"
+    },
+    "snapshot": null,
+    "ips": [{
+            "id": "8C4F2B7115EB90C585EE6FFB6A5904A8",
+            "ip": "70.35.203.100",
+            "type": "IPV4",
+            "reverse_dns": null,
+            "firewall_policy": {
+                "id": "34A7E423DA3253E6D38563ED06F1041F",
+                "name": "Linux"
+            },
+            "load_balancers": []
+        }],
+    "alerts": [],
+    "monitoring_policy": null,
+    "private_networks": null
+}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/7df28d25/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 716eac6..eefd791 100644
--- a/pom.xml
+++ b/pom.xml
@@ -16,8 +16,7 @@
     See the License for the specific language governing permissions and
     limitations under the License.
 
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/maven-v4_0_0.xsd";>
+--><project xmlns="http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/maven-v4_0_0.xsd";>
   <modelVersion>4.0.0</modelVersion>
   <parent>
     <groupId>org.apache.jclouds</groupId>
@@ -83,6 +82,7 @@
     <module>joyentcloud</module>
     <module>abiquo</module>
     <module>profitbricks-rest</module>
+    <module>oneandone</module>
   </modules>
 
   <build>
@@ -194,5 +194,4 @@
       </build>
     </profile>
   </profiles>
-</project>
-
+</project>
\ No newline at end of file

Reply via email to