You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jclouds.apache.org by de...@apache.org on 2016/02/19 16:33:17 UTC

[07/35] jclouds git commit: JCLOUDS-702: JClouds ProfitBricks provider - Storage API

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/image/ImageListResponseHandlerTest.java
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/image/ImageListResponseHandlerTest.java b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/image/ImageListResponseHandlerTest.java
index 0aa8f58..4827138 100644
--- a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/image/ImageListResponseHandlerTest.java
+++ b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/image/ImageListResponseHandlerTest.java
@@ -27,157 +27,157 @@ import static org.testng.Assert.assertEquals;
 import static org.testng.Assert.assertNotNull;
 import org.testng.annotations.Test;
 
-@Test( groups = "unit", testName = "ImageListResponseHandlerTest" )
+@Test(groups = "unit", testName = "ImageListResponseHandlerTest")
 public class ImageListResponseHandlerTest extends BaseResponseHandlerTest<List<Image>> {
 
    @Override
    protected ParseSax<List<Image>> createParser() {
-      return factory.create( injector.getInstance( ImageListResponseHandler.class ) );
+      return factory.create(injector.getInstance(ImageListResponseHandler.class));
    }
 
    @Test
    public void testParseResponseFromGetAllImages() {
       ParseSax<List<Image>> parser = createParser();
 
-      List<Image> actual = parser.parse( payloadFromResource( "/image/images.xml" ) );
-      assertNotNull( actual, "Parsed content returned null" );
+      List<Image> actual = parser.parse(payloadFromResource("/image/images.xml"));
+      assertNotNull(actual, "Parsed content returned null");
 
       List<Image> expected = ImmutableList.<Image>of(
               Image.builder()
-              .isBootable( true )
-              .isCpuHotPlug( true )
-              .isCpuHotUnPlug( false )
-              .isDiscVirtioHotPlug( true )
-              .isDiscVirtioHotUnPlug( true )
-              .id( "e4f73936-9161-11e4-9d74-52540066fee9" )
-              .name( "Ubuntu-12.04-LTS-server-2015-01-01" )
-              .size( 2048f )
-              .type( Image.Type.HDD )
-              .location( Location.DE_FRA )
-              .isNicHotPlug( true )
-              .isNicHotUnPlug( true )
-              .osType( OsType.LINUX )
-              .isPublic( true )
-              .isRamHotPlug( true )
-              .isRamHotUnPlug( false )
-              .isWriteable( true )
+              .isBootable(true)
+              .isCpuHotPlug(true)
+              .isCpuHotUnPlug(false)
+              .isDiscVirtioHotPlug(true)
+              .isDiscVirtioHotUnPlug(true)
+              .id("e4f73936-9161-11e4-9d74-52540066fee9")
+              .name("Ubuntu-12.04-LTS-server-2015-01-01")
+              .size(2048f)
+              .type(Image.Type.HDD)
+              .location(Location.DE_FRA)
+              .isNicHotPlug(true)
+              .isNicHotUnPlug(true)
+              .osType(OsType.LINUX)
+              .isPublic(true)
+              .isRamHotPlug(true)
+              .isRamHotUnPlug(false)
+              .isWriteable(true)
               .build(),
               Image.builder()
-              .isBootable( true )
-              .isCpuHotPlug( true )
-              .isCpuHotUnPlug( false )
-              .isDiscVirtioHotPlug( true )
-              .isDiscVirtioHotUnPlug( true )
-              .id( "a984a5d3-9163-11e4-9d74-52540066fee9" )
-              .name( "Ubuntu-14.04-LTS-server-2015-01-01" )
-              .size( 2048f )
-              .type( Image.Type.HDD )
-              .location( Location.DE_FRA )
-              .isNicHotPlug( true )
-              .isNicHotUnPlug( true )
-              .osType( OsType.LINUX )
-              .isPublic( true )
-              .isRamHotPlug( true )
-              .isRamHotUnPlug( false )
-              .isWriteable( true )
+              .isBootable(true)
+              .isCpuHotPlug(true)
+              .isCpuHotUnPlug(false)
+              .isDiscVirtioHotPlug(true)
+              .isDiscVirtioHotUnPlug(true)
+              .id("a984a5d3-9163-11e4-9d74-52540066fee9")
+              .name("Ubuntu-14.04-LTS-server-2015-01-01")
+              .size(2048f)
+              .type(Image.Type.HDD)
+              .location(Location.DE_FRA)
+              .isNicHotPlug(true)
+              .isNicHotUnPlug(true)
+              .osType(OsType.LINUX)
+              .isPublic(true)
+              .isRamHotPlug(true)
+              .isRamHotUnPlug(false)
+              .isWriteable(true)
               .build(),
               Image.builder()
-              .isBootable( true )
-              .isCpuHotPlug( true )
-              .isCpuHotUnPlug( false )
-              .isDiscVirtioHotPlug( true )
-              .isDiscVirtioHotUnPlug( true )
-              .id( "5f3cac96-915f-11e4-9d74-52540066fee9" )
-              .name( "Debian-jessie-prerelease-server-2015-01-01" )
-              .size( 2048f )
-              .type( Image.Type.HDD )
-              .location( Location.UNRECOGNIZED )
-              .isNicHotPlug( true )
-              .isNicHotUnPlug( true )
-              .osType( OsType.LINUX )
-              .isPublic( true )
-              .isRamHotPlug( true )
-              .isRamHotUnPlug( false )
-              .isWriteable( true )
+              .isBootable(true)
+              .isCpuHotPlug(true)
+              .isCpuHotUnPlug(false)
+              .isDiscVirtioHotPlug(true)
+              .isDiscVirtioHotUnPlug(true)
+              .id("5f3cac96-915f-11e4-9d74-52540066fee9")
+              .name("Debian-jessie-prerelease-server-2015-01-01")
+              .size(2048f)
+              .type(Image.Type.HDD)
+              .location(Location.UNRECOGNIZED)
+              .isNicHotPlug(true)
+              .isNicHotUnPlug(true)
+              .osType(OsType.LINUX)
+              .isPublic(true)
+              .isRamHotPlug(true)
+              .isRamHotUnPlug(false)
+              .isWriteable(true)
               .build(),
               Image.builder()
-              .isBootable( true )
-              .isCpuHotPlug( true )
-              .isCpuHotUnPlug( false )
-              .isDiscVirtioHotPlug( true )
-              .isDiscVirtioHotUnPlug( true )
-              .id( "f4742db0-9160-11e4-9d74-52540066fee9" )
-              .name( "Fedora-19-server-2015-01-01" )
-              .size( 2048f )
-              .type( Image.Type.HDD )
-              .location( Location.UNRECOGNIZED )
-              .isNicHotPlug( true )
-              .isNicHotUnPlug( true )
-              .osType( OsType.LINUX )
-              .isPublic( true )
-              .isRamHotPlug( true )
-              .isRamHotUnPlug( false )
-              .isWriteable( true )
+              .isBootable(true)
+              .isCpuHotPlug(true)
+              .isCpuHotUnPlug(false)
+              .isDiscVirtioHotPlug(true)
+              .isDiscVirtioHotUnPlug(true)
+              .id("f4742db0-9160-11e4-9d74-52540066fee9")
+              .name("Fedora-19-server-2015-01-01")
+              .size(2048f)
+              .type(Image.Type.HDD)
+              .location(Location.UNRECOGNIZED)
+              .isNicHotPlug(true)
+              .isNicHotUnPlug(true)
+              .osType(OsType.LINUX)
+              .isPublic(true)
+              .isRamHotPlug(true)
+              .isRamHotUnPlug(false)
+              .isWriteable(true)
               .build(),
               Image.builder()
-              .isBootable( true )
-              .isCpuHotPlug( true )
-              .isCpuHotUnPlug( false )
-              .isDiscVirtioHotPlug( true )
-              .isDiscVirtioHotUnPlug( true )
-              .id( "86902c18-9164-11e4-9d74-52540066fee9" )
-              .name( "Ubuntu-12.04-LTS-server-2015-01-01" )
-              .size( 2048f )
-              .type( Image.Type.HDD )
-              .location( Location.UNRECOGNIZED )
-              .isNicHotPlug( true )
-              .isNicHotUnPlug( true )
-              .osType( OsType.LINUX )
-              .isPublic( true )
-              .isRamHotPlug( true )
-              .isRamHotUnPlug( false )
-              .isWriteable( true )
+              .isBootable(true)
+              .isCpuHotPlug(true)
+              .isCpuHotUnPlug(false)
+              .isDiscVirtioHotPlug(true)
+              .isDiscVirtioHotUnPlug(true)
+              .id("86902c18-9164-11e4-9d74-52540066fee9")
+              .name("Ubuntu-12.04-LTS-server-2015-01-01")
+              .size(2048f)
+              .type(Image.Type.HDD)
+              .location(Location.UNRECOGNIZED)
+              .isNicHotPlug(true)
+              .isNicHotUnPlug(true)
+              .osType(OsType.LINUX)
+              .isPublic(true)
+              .isRamHotPlug(true)
+              .isRamHotUnPlug(false)
+              .isWriteable(true)
               .build(),
               Image.builder()
-              .isBootable( true )
-              .isCpuHotPlug( true )
-              .isCpuHotUnPlug( false )
-              .isDiscVirtioHotPlug( true )
-              .isDiscVirtioHotUnPlug( true )
-              .id( "3b48e3ff-9163-11e4-9d74-52540066fee9" )
-              .name( "Ubuntu-14.04-LTS-server-2015-01-01" )
-              .size( 2048f )
-              .type( Image.Type.HDD )
-              .location( Location.DE_FKB )
-              .isNicHotPlug( true )
-              .isNicHotUnPlug( true )
-              .osType( OsType.LINUX )
-              .isPublic( true )
-              .isRamHotPlug( true )
-              .isRamHotUnPlug( false )
-              .isWriteable( true )
+              .isBootable(true)
+              .isCpuHotPlug(true)
+              .isCpuHotUnPlug(false)
+              .isDiscVirtioHotPlug(true)
+              .isDiscVirtioHotUnPlug(true)
+              .id("3b48e3ff-9163-11e4-9d74-52540066fee9")
+              .name("Ubuntu-14.04-LTS-server-2015-01-01")
+              .size(2048f)
+              .type(Image.Type.HDD)
+              .location(Location.DE_FKB)
+              .isNicHotPlug(true)
+              .isNicHotUnPlug(true)
+              .osType(OsType.LINUX)
+              .isPublic(true)
+              .isRamHotPlug(true)
+              .isRamHotUnPlug(false)
+              .isWriteable(true)
               .build(),
               Image.builder()
-              .isBootable( true )
-              .isCpuHotPlug( true )
-              .isCpuHotUnPlug( false )
-              .isDiscVirtioHotPlug( true )
-              .isDiscVirtioHotUnPlug( true )
-              .id( "6ce17716-9164-11e4-9d74-52540066fee9" )
-              .name( "Ubuntu-12.04-LTS-server-2015-01-01" )
-              .size( 2048f )
-              .type( Image.Type.HDD )
-              .location( Location.US_LAS )
-              .isNicHotPlug( true )
-              .isNicHotUnPlug( true )
-              .osType( OsType.LINUX )
-              .isPublic( true )
-              .isRamHotPlug( true )
-              .isRamHotUnPlug( false )
-              .isWriteable( true )
+              .isBootable(true)
+              .isCpuHotPlug(true)
+              .isCpuHotUnPlug(false)
+              .isDiscVirtioHotPlug(true)
+              .isDiscVirtioHotUnPlug(true)
+              .id("6ce17716-9164-11e4-9d74-52540066fee9")
+              .name("Ubuntu-12.04-LTS-server-2015-01-01")
+              .size(2048f)
+              .type(Image.Type.HDD)
+              .location(Location.US_LAS)
+              .isNicHotPlug(true)
+              .isNicHotUnPlug(true)
+              .osType(OsType.LINUX)
+              .isPublic(true)
+              .isRamHotPlug(true)
+              .isRamHotUnPlug(false)
+              .isWriteable(true)
               .build()
       );
 
-      assertEquals( expected, actual );
+      assertEquals(expected, actual);
    }
 }

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerIdOnlyResponseHandlerTest.java
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerIdOnlyResponseHandlerTest.java b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerIdOnlyResponseHandlerTest.java
index 700b1e5..19bc29d 100644
--- a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerIdOnlyResponseHandlerTest.java
+++ b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerIdOnlyResponseHandlerTest.java
@@ -21,20 +21,20 @@ import org.jclouds.profitbricks.http.parser.BaseResponseHandlerTest;
 import static org.testng.Assert.assertEquals;
 import org.testng.annotations.Test;
 
-@Test( groups = "unit", testName = "ServerIdOnlyResponseHandlerTest" )
+@Test(groups = "unit", testName = "ServerIdOnlyResponseHandlerTest")
 public class ServerIdOnlyResponseHandlerTest extends BaseResponseHandlerTest<String> {
 
    @Override
    protected ParseSax<String> createParser() {
-      return factory.create( injector.getInstance( ServerIdOnlyResponseHandler.class ) );
+      return factory.create(injector.getInstance(ServerIdOnlyResponseHandler.class));
    }
 
    @Test
    public void testParseResponseFromCreateServer() {
       ParseSax<String> parser = createParser();
 
-      String serverId = parser.parse( payloadFromResource( "/server/server-create.xml" ) );
+      String serverId = parser.parse(payloadFromResource("/server/server-create.xml"));
 
-      assertEquals( "qwertyui-qwer-qwer-qwer-qwertyyuiiop", serverId );
+      assertEquals("qwertyui-qwer-qwer-qwer-qwertyyuiiop", serverId);
    }
 }

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerInfoResponseHandlerTest.java
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerInfoResponseHandlerTest.java b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerInfoResponseHandlerTest.java
index 734e169..b050568 100644
--- a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerInfoResponseHandlerTest.java
+++ b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerInfoResponseHandlerTest.java
@@ -16,7 +16,9 @@
  */
 package org.jclouds.profitbricks.http.parser.server;
 
-import java.text.ParseException;
+import static org.testng.Assert.assertEquals;
+import static org.testng.Assert.assertNotNull;
+
 import org.jclouds.date.DateCodec;
 import org.jclouds.date.DateCodecFactory;
 import org.jclouds.http.functions.ParseSax;
@@ -25,52 +27,51 @@ import org.jclouds.profitbricks.domain.OsType;
 import org.jclouds.profitbricks.domain.ProvisioningState;
 import org.jclouds.profitbricks.domain.Server;
 import org.jclouds.profitbricks.http.parser.BaseResponseHandlerTest;
-import static org.testng.Assert.assertEquals;
-import static org.testng.Assert.assertNotNull;
+
 import org.testng.annotations.Test;
 
-@Test( groups = "unit", testName = "ServerInfoResponseHandlerTest" )
+@Test(groups = "unit", testName = "ServerInfoResponseHandlerTest")
 public class ServerInfoResponseHandlerTest extends BaseResponseHandlerTest<Server> {
 
    @Override
    protected ParseSax<Server> createParser() {
-      return factory.create( injector.getInstance( ServerInfoResponseHandler.class ) );
+      return factory.create(injector.getInstance(ServerInfoResponseHandler.class));
    }
 
    protected DateCodecFactory createDateParser() {
-      return injector.getInstance( DateCodecFactory.class );
+      return injector.getInstance(DateCodecFactory.class);
    }
 
    @Test
-   public void testParseResponseFromGetServer() throws ParseException {
+   public void testParseResponseFromGetServer() {
       ParseSax<Server> parser = createParser();
 
-      Server actual = parser.parse( payloadFromResource( "/server/server.xml" ) );
-      assertNotNull( actual, "Parsed content returned null" );
+      Server actual = parser.parse(payloadFromResource("/server/server.xml"));
+      assertNotNull(actual, "Parsed content returned null");
 
       DateCodec dateParser = createDateParser().iso8601();
 
       Server expected = Server.builder()
-              .id( "qwertyui-qwer-qwer-qwer-qwertyyuiiop" )
-              .name( "facebook-node" )
-              .cores( 4 )
-              .ram( 4096 )
-              .hasInternetAccess( true )
-              .state( ProvisioningState.AVAILABLE )
-              .status( Server.Status.RUNNING )
-              .creationTime( dateParser.toDate( "2014-12-04T07:09:23.138Z" ) )
-              .lastModificationTime( dateParser.toDate( "2014-12-12T03:08:35.629Z" ) )
-              .osType( OsType.LINUX )
-              .availabilityZone( AvailabilityZone.AUTO )
-              .isCpuHotPlug( true )
-              .isRamHotPlug( true )
-              .isNicHotPlug( true )
-              .isNicHotUnPlug( true )
-              .isDiscVirtioHotPlug( true )
-              .isDiscVirtioHotUnPlug( true )
+              .id("qwertyui-qwer-qwer-qwer-qwertyyuiiop")
+              .name("facebook-node")
+              .cores(4)
+              .ram(4096)
+              .hasInternetAccess(true)
+              .state(ProvisioningState.AVAILABLE)
+              .status(Server.Status.RUNNING)
+              .creationTime(dateParser.toDate("2014-12-04T07:09:23.138Z"))
+              .lastModificationTime(dateParser.toDate("2014-12-12T03:08:35.629Z"))
+              .osType(OsType.LINUX)
+              .availabilityZone(AvailabilityZone.AUTO)
+              .isCpuHotPlug(true)
+              .isRamHotPlug(true)
+              .isNicHotPlug(true)
+              .isNicHotUnPlug(true)
+              .isDiscVirtioHotPlug(true)
+              .isDiscVirtioHotUnPlug(true)
               .build();
 
-      assertEquals( actual, expected );
+      assertEquals(actual, expected);
    }
 
 }

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerListResponseHandlerTest.java
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerListResponseHandlerTest.java b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerListResponseHandlerTest.java
index c9c01c6..09ee5bb 100644
--- a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerListResponseHandlerTest.java
+++ b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/server/ServerListResponseHandlerTest.java
@@ -30,68 +30,68 @@ import static org.testng.Assert.assertEquals;
 import static org.testng.Assert.assertNotNull;
 import org.testng.annotations.Test;
 
-@Test( groups = "unit", testName = "ServerListResponseHandlerTest" )
+@Test(groups = "unit", testName = "ServerListResponseHandlerTest")
 public class ServerListResponseHandlerTest extends BaseResponseHandlerTest<List<Server>> {
 
    @Override
    protected ParseSax<List<Server>> createParser() {
-      return factory.create( injector.getInstance( ServerListResponseHandler.class ) );
+      return factory.create(injector.getInstance(ServerListResponseHandler.class));
    }
 
    protected DateCodecFactory createDateParser() {
-      return injector.getInstance( DateCodecFactory.class );
+      return injector.getInstance(DateCodecFactory.class);
    }
 
    @Test
    public void testParseResponseFromGetAllServers() {
       ParseSax<List<Server>> parser = createParser();
 
-      List<Server> actual = parser.parse( payloadFromResource( "/server/servers.xml" ) );
-      assertNotNull( actual, "Parsed content returned null" );
+      List<Server> actual = parser.parse(payloadFromResource("/server/servers.xml"));
+      assertNotNull(actual, "Parsed content returned null");
 
       DateCodec dateParser = createDateParser().iso8601();
 
       List<Server> expected = ImmutableList.<Server>of(
               Server.builder()
-              .id( "qwertyui-qwer-qwer-qwer-qwertyyuiiop" )
-              .name( "facebook-node" )
-              .cores( 4 )
-              .ram( 4096 )
-              .hasInternetAccess( true )
-              .state( ProvisioningState.AVAILABLE )
-              .status( Server.Status.RUNNING )
-              .creationTime( dateParser.toDate( "2014-12-04T07:09:23.138Z" ) )
-              .lastModificationTime( dateParser.toDate( "2014-12-12T03:08:35.629Z" ) )
-              .osType( OsType.LINUX )
-              .availabilityZone( AvailabilityZone.AUTO )
-              .isCpuHotPlug( true )
-              .isRamHotPlug( true )
-              .isNicHotPlug( true )
-              .isNicHotUnPlug( true )
-              .isDiscVirtioHotPlug( true )
-              .isDiscVirtioHotUnPlug( true )
+              .id("qwertyui-qwer-qwer-qwer-qwertyyuiiop")
+              .name("facebook-node")
+              .cores(4)
+              .ram(4096)
+              .hasInternetAccess(true)
+              .state(ProvisioningState.AVAILABLE)
+              .status(Server.Status.RUNNING)
+              .creationTime(dateParser.toDate("2014-12-04T07:09:23.138Z"))
+              .lastModificationTime(dateParser.toDate("2014-12-12T03:08:35.629Z"))
+              .osType(OsType.LINUX)
+              .availabilityZone(AvailabilityZone.AUTO)
+              .isCpuHotPlug(true)
+              .isRamHotPlug(true)
+              .isNicHotPlug(true)
+              .isNicHotUnPlug(true)
+              .isDiscVirtioHotPlug(true)
+              .isDiscVirtioHotUnPlug(true)
               .build(),
               Server.builder()
-              .id( "asdfghjk-asdf-asdf-asdf-asdfghjklkjl" )
-              .name( "google-node" )
-              .cores( 1 )
-              .ram( 1024 )
-              .hasInternetAccess( false )
-              .state( ProvisioningState.AVAILABLE )
-              .status( Server.Status.RUNNING )
-              .creationTime( dateParser.toDate( "2014-11-12T07:01:00.441Z" ) )
-              .lastModificationTime( dateParser.toDate( "2014-11-12T07:01:00.441Z" ) )
-              .osType( OsType.LINUX )
-              .availabilityZone( AvailabilityZone.AUTO )
-              .isCpuHotPlug( true )
-              .isRamHotPlug( true )
-              .isNicHotPlug( true )
-              .isNicHotUnPlug( true )
-              .isDiscVirtioHotPlug( true )
-              .isDiscVirtioHotUnPlug( true )
+              .id("asdfghjk-asdf-asdf-asdf-asdfghjklkjl")
+              .name("google-node")
+              .cores(1)
+              .ram(1024)
+              .hasInternetAccess(false)
+              .state(ProvisioningState.AVAILABLE)
+              .status(Server.Status.RUNNING)
+              .creationTime(dateParser.toDate("2014-11-12T07:01:00.441Z"))
+              .lastModificationTime(dateParser.toDate("2014-11-12T07:01:00.441Z"))
+              .osType(OsType.LINUX)
+              .availabilityZone(AvailabilityZone.AUTO)
+              .isCpuHotPlug(true)
+              .isRamHotPlug(true)
+              .isNicHotPlug(true)
+              .isNicHotUnPlug(true)
+              .isDiscVirtioHotPlug(true)
+              .isDiscVirtioHotUnPlug(true)
               .build()
       );
 
-      assertEquals( actual, expected );
+      assertEquals(actual, expected);
    }
 }

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/state/GetProvisioningStateResponseHandlerTest.java
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/state/GetProvisioningStateResponseHandlerTest.java b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/state/GetProvisioningStateResponseHandlerTest.java
index 0f9822b..3bd2755 100644
--- a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/state/GetProvisioningStateResponseHandlerTest.java
+++ b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/state/GetProvisioningStateResponseHandlerTest.java
@@ -40,70 +40,70 @@ public class GetProvisioningStateResponseHandlerTest extends BaseResponseHandler
       ParseSax<ProvisioningState> parser = createParser();
 
       for (Map.Entry<ProvisioningState, String> pair : sampleResponses.entrySet()) {
-	 ProvisioningState actual = parser.parse(pair.getValue());
-	 assertNotNull(actual, "Parsed content returned null");
+         ProvisioningState actual = parser.parse(pair.getValue());
+         assertNotNull(actual, "Parsed content returned null");
 
-	 assertEquals(pair.getKey(), actual);
+         assertEquals(pair.getKey(), actual);
       }
 
    }
 
    private final Map<ProvisioningState, String> sampleResponses = new LinkedHashMap<ProvisioningState, String>() {
       {
-	 put(ProvisioningState.INACTIVE,
-		 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
-		 + "   <soapenv:Header/>\n"
-		 + "   <soapenv:Body>\n"
-		 + "      <ws:getDataCenterStateResponse>\n"
-		 + "         <return>INACTIVE</return>\n"
-		 + "      </ws:getDataCenterStateResponse>\n"
-		 + "   </soapenv:Body>\n"
-		 + "</soapenv:Envelope>");
-	 put(ProvisioningState.INPROCESS,
-		 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
-		 + "   <soapenv:Header/>\n"
-		 + "   <soapenv:Body>\n"
-		 + "      <ws:getDataCenterStateResponse>\n"
-		 + "         <return>INPROCESS</return>\n"
-		 + "      </ws:getDataCenterStateResponse>\n"
-		 + "   </soapenv:Body>\n"
-		 + "</soapenv:Envelope>");
-	 put(ProvisioningState.AVAILABLE,
-		 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
-		 + "   <soapenv:Header/>\n"
-		 + "   <soapenv:Body>\n"
-		 + "      <ws:getDataCenterStateResponse>\n"
-		 + "         <return>AVAILABLE</return>\n"
-		 + "      </ws:getDataCenterStateResponse>\n"
-		 + "   </soapenv:Body>\n"
-		 + "</soapenv:Envelope>");
-	 put(ProvisioningState.DELETED,
-		 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
-		 + "   <soapenv:Header/>\n"
-		 + "   <soapenv:Body>\n"
-		 + "      <ws:getDataCenterStateResponse>\n"
-		 + "         <return>DELETED</return>\n"
-		 + "      </ws:getDataCenterStateResponse>\n"
-		 + "   </soapenv:Body>\n"
-		 + "</soapenv:Envelope>");
-	 put(ProvisioningState.ERROR,
-		 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
-		 + "   <soapenv:Header/>\n"
-		 + "   <soapenv:Body>\n"
-		 + "      <ws:getDataCenterStateResponse>\n"
-		 + "         <return>ERROR</return>\n"
-		 + "      </ws:getDataCenterStateResponse>\n"
-		 + "   </soapenv:Body>\n"
-		 + "</soapenv:Envelope>");
-	 put(ProvisioningState.UNRECOGNIZED,
-		 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
-		 + "   <soapenv:Header/>\n"
-		 + "   <soapenv:Body>\n"
-		 + "      <ws:getDataCenterStateResponse>\n"
-		 + "         <return>MEH</return>\n"
-		 + "      </ws:getDataCenterStateResponse>\n"
-		 + "   </soapenv:Body>\n"
-		 + "</soapenv:Envelope>");
+         put(ProvisioningState.INACTIVE,
+                 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
+                 + "   <soapenv:Header/>\n"
+                 + "   <soapenv:Body>\n"
+                 + "      <ws:getDataCenterStateResponse>\n"
+                 + "         <return>INACTIVE</return>\n"
+                 + "      </ws:getDataCenterStateResponse>\n"
+                 + "   </soapenv:Body>\n"
+                 + "</soapenv:Envelope>");
+         put(ProvisioningState.INPROCESS,
+                 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
+                 + "   <soapenv:Header/>\n"
+                 + "   <soapenv:Body>\n"
+                 + "      <ws:getDataCenterStateResponse>\n"
+                 + "         <return>INPROCESS</return>\n"
+                 + "      </ws:getDataCenterStateResponse>\n"
+                 + "   </soapenv:Body>\n"
+                 + "</soapenv:Envelope>");
+         put(ProvisioningState.AVAILABLE,
+                 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
+                 + "   <soapenv:Header/>\n"
+                 + "   <soapenv:Body>\n"
+                 + "      <ws:getDataCenterStateResponse>\n"
+                 + "         <return>AVAILABLE</return>\n"
+                 + "      </ws:getDataCenterStateResponse>\n"
+                 + "   </soapenv:Body>\n"
+                 + "</soapenv:Envelope>");
+         put(ProvisioningState.DELETED,
+                 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
+                 + "   <soapenv:Header/>\n"
+                 + "   <soapenv:Body>\n"
+                 + "      <ws:getDataCenterStateResponse>\n"
+                 + "         <return>DELETED</return>\n"
+                 + "      </ws:getDataCenterStateResponse>\n"
+                 + "   </soapenv:Body>\n"
+                 + "</soapenv:Envelope>");
+         put(ProvisioningState.ERROR,
+                 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
+                 + "   <soapenv:Header/>\n"
+                 + "   <soapenv:Body>\n"
+                 + "      <ws:getDataCenterStateResponse>\n"
+                 + "         <return>ERROR</return>\n"
+                 + "      </ws:getDataCenterStateResponse>\n"
+                 + "   </soapenv:Body>\n"
+                 + "</soapenv:Envelope>");
+         put(ProvisioningState.UNRECOGNIZED,
+                 "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">\n"
+                 + "   <soapenv:Header/>\n"
+                 + "   <soapenv:Body>\n"
+                 + "      <ws:getDataCenterStateResponse>\n"
+                 + "         <return>MEH</return>\n"
+                 + "      </ws:getDataCenterStateResponse>\n"
+                 + "   </soapenv:Body>\n"
+                 + "</soapenv:Envelope>");
       }
    };
 

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageIdOnlyResponseHandlerTest.java
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageIdOnlyResponseHandlerTest.java b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageIdOnlyResponseHandlerTest.java
new file mode 100644
index 0000000..def23b6
--- /dev/null
+++ b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageIdOnlyResponseHandlerTest.java
@@ -0,0 +1,42 @@
+/*
+ * 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.jclouds.profitbricks.http.parser.storage;
+
+import static org.testng.Assert.assertEquals;
+
+import org.jclouds.http.functions.ParseSax;
+import org.jclouds.profitbricks.http.parser.BaseResponseHandlerTest;
+import org.testng.annotations.Test;
+
+@Test(groups = "unit", testName = "StorageIdOnlyResponseHandlerTest")
+public class StorageIdOnlyResponseHandlerTest extends BaseResponseHandlerTest<String> {
+
+   @Override
+   protected ParseSax<String> createParser() {
+      return factory.create(injector.getInstance(StorageIdOnlyResponseHandler.class));
+   }
+
+   @Test
+   public void testParseResponseFromCreateStorage() {
+      ParseSax<String> parser = createParser();
+
+      String storageId = parser.parse(payloadFromResource("/storage/storage-create.xml"));
+
+      assertEquals("qswdefrg-qaws-qaws-defe-rgrgdsvcxbrh", storageId);
+   }
+
+}

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageInfoResponseHandlerTest.java
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageInfoResponseHandlerTest.java b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageInfoResponseHandlerTest.java
new file mode 100644
index 0000000..338b02b
--- /dev/null
+++ b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageInfoResponseHandlerTest.java
@@ -0,0 +1,66 @@
+/*
+ * 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.jclouds.profitbricks.http.parser.storage;
+
+import static org.testng.Assert.assertEquals;
+import static org.testng.Assert.assertNotNull;
+
+import org.jclouds.date.DateCodec;
+import org.jclouds.date.DateCodecFactory;
+import org.jclouds.http.functions.ParseSax;
+import org.jclouds.profitbricks.domain.ProvisioningState;
+import org.jclouds.profitbricks.domain.Storage;
+import org.jclouds.profitbricks.http.parser.BaseResponseHandlerTest;
+import org.testng.annotations.Test;
+
+import com.google.common.collect.ImmutableList;
+
+@Test(groups = "unit", testName = "StorageInfoResponseHandlerTest")
+public class StorageInfoResponseHandlerTest extends BaseResponseHandlerTest<Storage> {
+
+   @Override
+   protected ParseSax<Storage> createParser() {
+      return factory.create(injector.getInstance(StorageInfoResponseHandler.class));
+   }
+
+   protected DateCodecFactory createDateParser() {
+      return injector.getInstance(DateCodecFactory.class);
+   }
+
+   @Test
+   public void testParseResponseFromGetStorage() {
+      ParseSax<Storage> parser = createParser();
+
+      Storage actual = parser.parse(payloadFromResource("/storage/storage.xml"));
+      assertNotNull(actual, "Parsed content returned null");
+
+      DateCodec dateParser = createDateParser().iso8601();
+
+      Storage expected = Storage.builder()
+              .id("qswdefrg-qaws-qaws-defe-rgrgdsvcxbrh")
+              .size(40)
+              .name("hdd-1")
+              .state(ProvisioningState.AVAILABLE)
+              .serverIds(ImmutableList.<String>of("qwertyui-qwer-qwer-qwer-qwertyyuiiop"))
+              .creationTime(dateParser.toDate("2014-12-04T07:09:23.138Z"))
+              .lastModificationTime(dateParser.toDate("2014-12-12T03:14:48.316Z"))
+              .build();
+
+      assertEquals(actual, expected);
+   }
+
+}

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageListResponseHandlerTest.java
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageListResponseHandlerTest.java b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageListResponseHandlerTest.java
new file mode 100644
index 0000000..62e43fc
--- /dev/null
+++ b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/http/parser/storage/StorageListResponseHandlerTest.java
@@ -0,0 +1,80 @@
+/*
+ * 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.jclouds.profitbricks.http.parser.storage;
+
+import static org.testng.Assert.assertEquals;
+import static org.testng.Assert.assertNotNull;
+
+import com.google.common.collect.ImmutableList;
+
+import java.util.List;
+
+import org.jclouds.date.DateCodec;
+import org.jclouds.date.DateCodecFactory;
+import org.jclouds.http.functions.ParseSax;
+import org.jclouds.profitbricks.domain.ProvisioningState;
+import org.jclouds.profitbricks.domain.Storage;
+import org.jclouds.profitbricks.http.parser.BaseResponseHandlerTest;
+
+import org.testng.annotations.Test;
+
+@Test(groups = "unit", testName = "StorageListResponseHandlerTest")
+public class StorageListResponseHandlerTest extends BaseResponseHandlerTest<List<Storage>> {
+
+   @Override
+   protected ParseSax<List<Storage>> createParser() {
+      return factory.create(injector.getInstance(StorageListResponseHandler.class));
+   }
+
+   protected DateCodecFactory createDateParser() {
+      return injector.getInstance(DateCodecFactory.class);
+   }
+
+   @Test
+   public void testParseResponseFromGetAllStorages() {
+      ParseSax<List<Storage>> parser = createParser();
+
+      List<Storage> actual = parser.parse(payloadFromResource("/storage/storages.xml"));
+      assertNotNull(actual, "Parsed content returned null");
+
+      DateCodec dateParser = createDateParser().iso8601();
+
+      List<Storage> expected = ImmutableList.<Storage>of(
+              Storage.builder()
+              .id("qswdefrg-qaws-qaws-defe-rgrgdsvcxbrh")
+              .size(40f)
+              .name("hdd-1")
+              .state(ProvisioningState.AVAILABLE)
+              .serverIds(ImmutableList.<String>of("qwertyui-qwer-qwer-qwer-qwertyyuiiop"))
+              .creationTime(dateParser.toDate("2014-12-04T07:09:23.138Z"))
+              .lastModificationTime(dateParser.toDate("2014-12-12T03:14:48.316Z"))
+              .build(),
+              Storage.builder()
+              .id("asfasfle-f23n-cu89-klfr-njkdsvwllkfa")
+              .size(100f)
+              .name("hdd-2")
+              .state(ProvisioningState.INPROCESS)
+              .serverIds(ImmutableList.<String>of("asdfghjk-asdf-asdf-asdf-asdfghjklkjl"))
+              .creationTime(dateParser.toDate("2014-11-04T07:09:23.138Z"))
+              .lastModificationTime(dateParser.toDate("2014-11-12T03:14:48.316Z"))
+              .build()
+      );
+
+      assertEquals(actual, expected);
+   }
+
+}

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/java/org/jclouds/profitbricks/internal/BaseProfitBricksMockTest.java
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/internal/BaseProfitBricksMockTest.java b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/internal/BaseProfitBricksMockTest.java
index 3e5d19a..d5883a6 100644
--- a/providers/profitbricks/src/test/java/org/jclouds/profitbricks/internal/BaseProfitBricksMockTest.java
+++ b/providers/profitbricks/src/test/java/org/jclouds/profitbricks/internal/BaseProfitBricksMockTest.java
@@ -46,11 +46,11 @@ public class BaseProfitBricksMockTest {
    protected static final String authHeader = BasicAuthentication.basic("username", "password");
    protected static final String provider = "profitbricks";
    protected static final String rootUrl = "/1.3";
-   
+
    private static final String SOAP_PREFIX
-	   = "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">"
-	   + "<soapenv:Header/>"
-	   + "<soapenv:Body>";
+           = "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:ws=\"http://ws.api.profitbricks.com/\">"
+           + "<soapenv:Header/>"
+           + "<soapenv:Body>";
 
    private static final String SOAP_SUFFIX = "</soapenv:Body></soapenv:Envelope>";
 
@@ -77,7 +77,7 @@ public class BaseProfitBricksMockTest {
       server.play();
       return server;
    }
-   
+
    public byte[] payloadFromResource(String resource) {
       try {
          return toStringAndClose(getClass().getResourceAsStream(resource)).getBytes(Charsets.UTF_8);
@@ -85,9 +85,9 @@ public class BaseProfitBricksMockTest {
          throw Throwables.propagate(e);
       }
    }
-   
-   protected static String payloadSoapWithBody(String body){
-      return SOAP_PREFIX.concat( body ).concat( SOAP_SUFFIX );
+
+   protected static String payloadSoapWithBody(String body) {
+      return SOAP_PREFIX.concat(body).concat(SOAP_SUFFIX);
    }
 
    protected static void assertRequestHasCommonProperties(final RecordedRequest request) {
@@ -96,9 +96,9 @@ public class BaseProfitBricksMockTest {
       assertEquals(request.getHeader(HttpHeaders.AUTHORIZATION), authHeader);
       assertEquals(request.getHeader(HttpHeaders.ACCEPT), MediaType.TEXT_XML);
    }
-   
-   protected static void assertRequestHasCommonProperties(final RecordedRequest request, String content ){
-      assertEquals( new String( request.getBody() ), payloadSoapWithBody( content ) );
-      assertRequestHasCommonProperties( request );
+
+   protected static void assertRequestHasCommonProperties(final RecordedRequest request, String content) {
+      assertEquals(new String(request.getBody()), payloadSoapWithBody(content));
+      assertRequestHasCommonProperties(request);
    }
 }

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/datacenter/datacenter.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/datacenter/datacenter.xml b/providers/profitbricks/src/test/resources/datacenter/datacenter.xml
index 2911c81..9d8e20a 100644
--- a/providers/profitbricks/src/test/resources/datacenter/datacenter.xml
+++ b/providers/profitbricks/src/test/resources/datacenter/datacenter.xml
@@ -33,7 +33,7 @@
                         <serverId>12345678-abcd-efgh-ijkl-987654321000</serverId>
                         <ips>202.94.38.12</ips>
                         <macAddress>02:01:09:cd:f0:b0</macAddress>
-                        <firewall>`
+                        <firewall>
                             <active>false</active>
                             <firewallId>llllllll-kkkk-jjjj-hhhh-gggggggggggg</firewallId>
                             <firewallId>62383ec1-38c8-486b-8fa2-a3bb0a5edd97</firewallId>

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/fault-404.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/fault-404.xml b/providers/profitbricks/src/test/resources/fault-404.xml
index 430be82..1875102 100644
--- a/providers/profitbricks/src/test/resources/fault-404.xml
+++ b/providers/profitbricks/src/test/resources/fault-404.xml
@@ -14,4 +14,4 @@
             </detail>
         </S:Fault>
     </S:Body>
-</S:Envelope>
+</S:Envelope>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/fault-413.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/fault-413.xml b/providers/profitbricks/src/test/resources/fault-413.xml
new file mode 100644
index 0000000..b4d5f79
--- /dev/null
+++ b/providers/profitbricks/src/test/resources/fault-413.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
+    <S:Body>
+        <S:Fault xmlns:ns4="http://www.w3.org/2003/05/soap-envelope">
+            <faultcode>S:Server</faultcode>
+            <faultstring>New request exceeds the current capacity settings of this user contract.  Please refer to Request Id : 16503940. [VDC-5-1020] Server  has 12,800 MiB configured RAM. Your personal limit is 10,240 MiB per server.</faultstring>
+            <detail>
+                <ns2:ProfitbricksServiceFault xmlns:ns2="http://ws.api.profitbricks.com/">
+                    <faultCode>OVER_LIMIT_SETTING</faultCode>
+                    <httpCode>413</httpCode>
+                    <message>New request exceeds the current capacity settings of this user contract.  Please refer to Request Id : 16503940. [VDC-5-1020] Server  has 12,800 MiB configured RAM. Your personal limit is 10,240 MiB per server.</message>
+                    <requestId>16503940</requestId>
+                </ns2:ProfitbricksServiceFault>
+            </detail>
+        </S:Fault>
+    </S:Body>
+</S:Envelope>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/maintenance-503.html
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/maintenance-503.html b/providers/profitbricks/src/test/resources/maintenance-503.html
new file mode 100644
index 0000000..bbc1b1f
--- /dev/null
+++ b/providers/profitbricks/src/test/resources/maintenance-503.html
@@ -0,0 +1,67 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+    <head>
+        <meta lang="en" http-equiv="Content-Type" content="text/html; charset=UTF-8" />
+        <title>Profitbricks | Maintenance</title>
+        <link rel="stylesheet" type="text/css" href="css/style.css" />
+        <link rel="stylesheet" type="text/css" href="css/content.css" />
+        <link rel="stylesheet" type="text/css" href="css/recent_additions.css" />
+        <link rel="shortcut icon" href="https://my.profitbricks.com/errorpages/favicon.ico" type="image/x-icon" />
+    </head>
+
+    <body>
+        <div class="head1 h_bg"></div>
+        <div class="head2 h_bg"></div>
+        <div class="head3 h_bg"></div>
+
+        <div id="wrapper">
+            <div class="wrapper_inner">
+
+                <div id="header">
+                    <a id="logo" href="#"><img alt="Profitbricks" src="img/logo.png" /></a>
+                </div>
+
+                <div id="main">
+                    <div id="right" style="min-height: 550px;">
+                        <div class="article msg">
+                            <h1>Maintenance</h1>
+                            <img width="49" height="49" title="" alt="message error" src="Profitbricks%20%7C%20Maintenance_files/msg_error.png" class="msg_sign" style="margin: 10px;" />
+                            <div class="container" style="margin:20px 80px !important;">
+                                <div class="bigmargin">
+                                    <h2>Dear ProfitBricks users,</h2>
+                                    <p>actually we are carrying out maintenance work right now.</p>
+                                    <p>For urgent matters please contact:<br /><a href="mailto:support@profitbricks.com">support@profitbricks.com</a>.</p>
+                                    <br />
+                                    <p>We ask for your understanding and your patience.</p>
+                                    <p>Your ProfitBricks Team</p>
+                                </div>
+
+                                <div class="bigmargin">
+                                    <h2>Sehr geehrte(r) ProfitBricks Nutzerin/Nutzer,</h2>
+                                    <p>zur Zeit führen wir Wartungsarbeiten durch.</p>
+                                    <p>Bei dringenden Angelegenheiten wenden Sie sich bitte an:<br />
+                                        <a href="mailto:support@profitbricks.com">support@profitbricks.com</a>
+                                    </p>
+                                    <br />
+                                    <p>Wir bitten Sie um Ihr Verständnis und um etwas Geduld.</p>
+                                    <p>Ihr ProfitBricks Team</p>
+                                </div>
+
+                            </div>
+                        </div>
+                    </div>
+                    <br class="clear" />
+                </div>
+
+            </div>
+        </div>
+
+        <div id="footer">
+            <div class="bottom">
+                <div class="inner">
+                </div>
+            </div>
+        </div>
+
+    </body>
+</html>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/server/server-state-inprocess.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/server/server-state-inprocess.xml b/providers/profitbricks/src/test/resources/server/server-state-inprocess.xml
new file mode 100644
index 0000000..122191a
--- /dev/null
+++ b/providers/profitbricks/src/test/resources/server/server-state-inprocess.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
+    <S:Body>
+        <ns2:getServerResponse xmlns:ns2="http://ws.api.profitbricks.com/">
+            <return>
+                <requestId>16577212</requestId>
+                <dataCenterId>aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee</dataCenterId>
+                <dataCenterVersion>22</dataCenterVersion>
+                <serverId>qwertyui-qwer-qwer-qwer-qwertyyuiiop</serverId>
+                <cores>1</cores>
+                <ram>512</ram>
+                <internetAccess>false</internetAccess>
+                <provisioningState>INPROCESS</provisioningState>
+                <virtualMachineState>NOSTATE</virtualMachineState>
+                <creationTime>2015-01-29T00:37:49.096Z</creationTime>
+                <lastModificationTime>2015-01-29T00:37:49.096Z</lastModificationTime>
+                <osType>UNKNOWN</osType>
+                <availabilityZone>AUTO</availabilityZone>
+                <cpuHotPlug>false</cpuHotPlug>
+                <ramHotPlug>false</ramHotPlug>
+                <nicHotPlug>false</nicHotPlug>
+                <nicHotUnPlug>false</nicHotUnPlug>
+                <discVirtioHotPlug>false</discVirtioHotPlug>
+                <discVirtioHotUnPlug>false</discVirtioHotUnPlug>
+            </return>
+        </ns2:getServerResponse>
+    </S:Body>
+</S:Envelope>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/storage/storage-connect.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/storage/storage-connect.xml b/providers/profitbricks/src/test/resources/storage/storage-connect.xml
new file mode 100644
index 0000000..79673e2
--- /dev/null
+++ b/providers/profitbricks/src/test/resources/storage/storage-connect.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ws="http://ws.api.profitbricks.com/">
+    <soapenv:Header/>
+    <soapenv:Body>
+        <ws:connectStorageToServerResponse>
+            <return>
+                <requestId>16463317</requestId>
+                <dataCenterId>aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee</dataCenterId>
+                <dataCenterVersion>49</dataCenterVersion>
+            </return>
+        </ws:connectStorageToServerResponse>
+    </soapenv:Body>
+</soapenv:Envelope>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/storage/storage-create.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/storage/storage-create.xml b/providers/profitbricks/src/test/resources/storage/storage-create.xml
new file mode 100644
index 0000000..3e1d1f3
--- /dev/null
+++ b/providers/profitbricks/src/test/resources/storage/storage-create.xml
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ws="http://ws.api.profitbricks.com/">
+    <soapenv:Header/>
+    <soapenv:Body>
+        <ws:createStorageReturn>
+            <return>
+                <requestId>1234567</requestId>
+                <dataCenterId>aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee</dataCenterId>
+                <dataCenterVersion>45</dataCenterVersion>
+                <storageId>qswdefrg-qaws-qaws-defe-rgrgdsvcxbrh</storageId>
+            </return>
+        </ws:createStorageReturn>
+    </soapenv:Body>
+</soapenv:Envelope>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/storage/storage-delete.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/storage/storage-delete.xml b/providers/profitbricks/src/test/resources/storage/storage-delete.xml
new file mode 100644
index 0000000..a973126
--- /dev/null
+++ b/providers/profitbricks/src/test/resources/storage/storage-delete.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ws="http://ws.api.profitbricks.com/">
+    <soapenv:Header/>
+    <soapenv:Body>
+        <ws:deleteStorageResponse>
+            <return>
+                <requestId>12345679</requestId>
+                <dataCenterId>aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee</dataCenterId>
+                <dataCenterVersion>47</dataCenterVersion>
+            </return>
+        </ws:deleteStorageResponse>
+    </soapenv:Body>
+</soapenv:Envelope>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/storage/storage-disconnect.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/storage/storage-disconnect.xml b/providers/profitbricks/src/test/resources/storage/storage-disconnect.xml
new file mode 100644
index 0000000..8726fe2
--- /dev/null
+++ b/providers/profitbricks/src/test/resources/storage/storage-disconnect.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ws="http://ws.api.profitbricks.com/">
+    <soapenv:Header/>
+    <soapenv:Body>
+        <ws:disconnectStorageFromServerResponse>
+            <return>
+                <requestId>16463318</requestId>
+                <dataCenterId>aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee</dataCenterId>
+                <dataCenterVersion>50</dataCenterVersion>
+            </return>
+        </ws:disconnectStorageFromServerResponse>
+    </soapenv:Body>
+</soapenv:Envelope>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/storage/storage-state-inprocess.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/storage/storage-state-inprocess.xml b/providers/profitbricks/src/test/resources/storage/storage-state-inprocess.xml
new file mode 100644
index 0000000..85c4717
--- /dev/null
+++ b/providers/profitbricks/src/test/resources/storage/storage-state-inprocess.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
+    <S:Body>
+        <ns2:getStorageResponse xmlns:ns2="http://ws.api.profitbricks.com/">
+            <return>
+                <requestId>16463316</requestId>
+                <dataCenterId>aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee</dataCenterId>
+                <dataCenterVersion>49</dataCenterVersion>
+                <storageId>qswdefrg-qaws-qaws-defe-rgrgdsvcxbrh</storageId>
+                <size>40</size>
+                <storageName>hdd-1</storageName>
+                <mountImage>
+                    <imageId>f0a59a5c-7940-11e4-8053-52540066fee9</imageId>
+                    <imageName>Ubuntu-14.04-LTS-server-2014-12-01</imageName>
+                </mountImage>
+                <serverIds>qwertyui-qwer-qwer-qwer-qwertyyuiiop</serverIds>
+                <provisioningState>INPROCESS</provisioningState>
+                <creationTime>2014-12-04T07:09:23.138Z</creationTime>
+                <lastModificationTime>2014-12-12T03:14:48.316Z</lastModificationTime>
+            </return>
+        </ns2:getStorageResponse>
+    </S:Body>
+</S:Envelope>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/storage/storage-update.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/storage/storage-update.xml b/providers/profitbricks/src/test/resources/storage/storage-update.xml
new file mode 100644
index 0000000..ff71f32
--- /dev/null
+++ b/providers/profitbricks/src/test/resources/storage/storage-update.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ws="http://ws.api.profitbricks.com/">
+    <soapenv:Header/>
+    <soapenv:Body>
+        <ws:updateStorageResponse>
+            <return>
+                <requestId>1234568</requestId>
+                <dataCenterId>aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee</dataCenterId>
+                <dataCenterVersion>46</dataCenterVersion>
+            </return>
+        </ws:updateStorageResponse>
+    </soapenv:Body>
+</soapenv:Envelope>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/storage/storage.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/storage/storage.xml b/providers/profitbricks/src/test/resources/storage/storage.xml
new file mode 100644
index 0000000..fe4dfc5
--- /dev/null
+++ b/providers/profitbricks/src/test/resources/storage/storage.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
+    <S:Body>
+        <ns2:getStorageResponse xmlns:ns2="http://ws.api.profitbricks.com/">
+            <return>
+                <requestId>16463316</requestId>
+                <dataCenterId>aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee</dataCenterId>
+                <dataCenterVersion>49</dataCenterVersion>
+                <storageId>qswdefrg-qaws-qaws-defe-rgrgdsvcxbrh</storageId>
+                <size>40</size>
+                <storageName>hdd-1</storageName>
+                <mountImage>
+                    <imageId>f0a59a5c-7940-11e4-8053-52540066fee9</imageId>
+                    <imageName>Ubuntu-14.04-LTS-server-2014-12-01</imageName>
+                </mountImage>
+                <serverIds>qwertyui-qwer-qwer-qwer-qwertyyuiiop</serverIds>
+                <provisioningState>AVAILABLE</provisioningState>
+                <creationTime>2014-12-04T07:09:23.138Z</creationTime>
+                <lastModificationTime>2014-12-12T03:14:48.316Z</lastModificationTime>
+            </return>
+        </ns2:getStorageResponse>
+    </S:Body>
+</S:Envelope>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/jclouds/blob/2a219a99/providers/profitbricks/src/test/resources/storage/storages.xml
----------------------------------------------------------------------
diff --git a/providers/profitbricks/src/test/resources/storage/storages.xml b/providers/profitbricks/src/test/resources/storage/storages.xml
new file mode 100644
index 0000000..a732861
--- /dev/null
+++ b/providers/profitbricks/src/test/resources/storage/storages.xml
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
+    <S:Body>
+        <ns2:getAllStoragesResponse xmlns:ns2="http://ws.api.profitbricks.com/">
+            <return>
+                <dataCenterId>aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee</dataCenterId>
+                <dataCenterVersion>49</dataCenterVersion>
+                <storageId>qswdefrg-qaws-qaws-defe-rgrgdsvcxbrh</storageId>
+                <size>40</size>
+                <storageName>hdd-1</storageName>
+                <mountImage>
+                    <imageId>f0a59a5c-7940-11e4-8053-52540066fee9</imageId>
+                    <imageName>Ubuntu-14.04-LTS-server-2014-12-01</imageName>
+                </mountImage>
+                <serverIds>qwertyui-qwer-qwer-qwer-qwertyyuiiop</serverIds>
+                <provisioningState>AVAILABLE</provisioningState>
+                <creationTime>2014-12-04T07:09:23.138Z</creationTime>
+                <lastModificationTime>2014-12-12T03:14:48.316Z</lastModificationTime>
+            </return>
+            <return>
+                <dataCenterId>qqqqqqqq-wwww-rrrr-tttt-yyyyyyyyyyyy</dataCenterId>
+                <dataCenterVersion>238</dataCenterVersion>
+                <storageId>asfasfle-f23n-cu89-klfr-njkdsvwllkfa</storageId>
+                <size>100</size>
+                <storageName>hdd-2</storageName>
+                <mountImage>
+                    <imageId>f4742db0-9160-11e4-9d74-52540066fee9</imageId>
+                    <imageName>Fedora-19-server-2015-01-01</imageName>
+                </mountImage>
+                <serverIds>asdfghjk-asdf-asdf-asdf-asdfghjklkjl</serverIds>
+                <provisioningState>INPROCESS</provisioningState>
+                <creationTime>2014-11-04T07:09:23.138Z</creationTime>
+                <lastModificationTime>2014-11-12T03:14:48.316Z</lastModificationTime>
+            </return>
+        </ns2:getAllStoragesResponse>
+    </S:Body>
+</S:Envelope>
\ No newline at end of file