static String getLocationFrom( HttpPost method ) {
    Header locationHeader = method.getFirstHeader( "Location" );
    return locationHeader.getValue();
  }
@Test
  public void getLocationFrom() {
    HttpPost postMethod = mock( HttpPost.class );
    Header locationHeader = new BasicHeader( LOCATION_HEADER, TEST_URL );
    doReturn( locationHeader ).when( postMethod ).getFirstHeader( LOCATION_HEADER );

    assertEquals( TEST_URL, WebService.getLocationFrom( postMethod ) );
  }