mirror of https://github.com/apache/jclouds.git
Enable range tests for azureblob
This commit is contained in:
parent
3a65df1e2e
commit
b2c0786fc0
|
@ -413,7 +413,7 @@ public class BaseBlobIntegrationTest extends BaseBlobStoreIntegrationTest {
|
||||||
Blob blob3 = view.getBlobStore().getBlob(container, name, new GetOptions().tail(TEST_STRING.length() + 10));
|
Blob blob3 = view.getBlobStore().getBlob(container, name, new GetOptions().tail(TEST_STRING.length() + 10));
|
||||||
validateMetadata(blob3.getMetadata(), container, name);
|
validateMetadata(blob3.getMetadata(), container, name);
|
||||||
assertEquals(getContentAsStringOrNullAndClose(blob3), TEST_STRING);
|
assertEquals(getContentAsStringOrNullAndClose(blob3), TEST_STRING);
|
||||||
assertThat(blob3.getAllHeaders().get(HttpHeaders.CONTENT_RANGE)).containsExactly("bytes 0-45/46");
|
// not all providers return Content-Range for non-partial responses
|
||||||
} finally {
|
} finally {
|
||||||
returnContainer(container);
|
returnContainer(container);
|
||||||
}
|
}
|
||||||
|
|
|
@ -331,15 +331,8 @@ public class AzureBlobClientLiveTest extends BaseBlobStoreIntegrationTest {
|
||||||
assertEquals(e.getResponse().getStatusCode(), 412);
|
assertEquals(e.getResponse().getStatusCode(), 412);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Range
|
getBlob = getApi().getBlob(privateContainer, object.getProperties().getName(), GetOptions.Builder.startAt(8));
|
||||||
// doesn't work per
|
assertEquals(Strings2.toStringAndClose(getBlob.getPayload().openStream()), data.substring(8));
|
||||||
// http://social.msdn.microsoft.com/Forums/en-US/windowsazure/thread/479fa63f-51df-4b66-96b5-33ae362747b6
|
|
||||||
// getBlob = getApi()
|
|
||||||
// .getBlob(privateContainer, object.getProperties().getName(),
|
|
||||||
// GetOptions.Builder.startAt(8)).get(120,
|
|
||||||
// TimeUnit.SECONDS);
|
|
||||||
// assertEquals(Utils.toStringAndClose((InputStream) getBlob.getData()),
|
|
||||||
// data.substring(8));
|
|
||||||
|
|
||||||
getApi().deleteBlob(privateContainer, "object");
|
getApi().deleteBlob(privateContainer, "object");
|
||||||
getApi().deleteBlob(privateContainer, "chunked-object");
|
getApi().deleteBlob(privateContainer, "chunked-object");
|
||||||
|
|
|
@ -64,10 +64,4 @@ public class AzureBlobIntegrationLiveTest extends BaseBlobIntegrationTest {
|
||||||
public void testPutBlobAccessMultipart() throws Exception {
|
public void testPutBlobAccessMultipart() throws Exception {
|
||||||
super.testPutBlobAccessMultipart();
|
super.testPutBlobAccessMultipart();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
@Test
|
|
||||||
public void testGetRange() {
|
|
||||||
throw new SkipException("Currently broken on Azure");
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue