kopia lustrzana https://github.com/gaul/s3proxy
Do not run marker tests when backend lacks support
rodzic
82d95a2746
commit
bc68e2cb2e
|
@ -45,6 +45,7 @@ public final class JcloudsBucketsLiveTest extends BucketsLiveTest {
|
||||||
"0"));
|
"0"));
|
||||||
private S3Proxy s3Proxy;
|
private S3Proxy s3Proxy;
|
||||||
private BlobStoreContext context;
|
private BlobStoreContext context;
|
||||||
|
private String blobStoreType;
|
||||||
|
|
||||||
@AfterClass
|
@AfterClass
|
||||||
public void tearDown() throws Exception {
|
public void tearDown() throws Exception {
|
||||||
|
@ -65,6 +66,7 @@ public final class JcloudsBucketsLiveTest extends BucketsLiveTest {
|
||||||
info = TestUtils.startS3Proxy();
|
info = TestUtils.startS3Proxy();
|
||||||
s3Proxy = info.getS3Proxy();
|
s3Proxy = info.getS3Proxy();
|
||||||
context = info.getBlobStore().getContext();
|
context = info.getBlobStore().getContext();
|
||||||
|
blobStoreType = context.unwrap().getProviderMetadata().getId();
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw Throwables.propagate(e);
|
throw Throwables.propagate(e);
|
||||||
}
|
}
|
||||||
|
@ -115,4 +117,13 @@ public final class JcloudsBucketsLiveTest extends BucketsLiveTest {
|
||||||
throw new SkipException("bucket logging not supported", are);
|
throw new SkipException("bucket logging not supported", are);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void testListBucketMarker()
|
||||||
|
throws InterruptedException, ExecutionException, TimeoutException {
|
||||||
|
if (Quirks.OPAQUE_MARKERS.contains(blobStoreType)) {
|
||||||
|
throw new SkipException("opaque markers not supported");
|
||||||
|
}
|
||||||
|
super.testListBucketMarker();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -25,6 +25,7 @@ import com.google.common.util.concurrent.Uninterruptibles;
|
||||||
import org.jclouds.Constants;
|
import org.jclouds.Constants;
|
||||||
import org.jclouds.blobstore.BlobStoreContext;
|
import org.jclouds.blobstore.BlobStoreContext;
|
||||||
import org.jclouds.s3.blobstore.integration.S3ContainerIntegrationLiveTest;
|
import org.jclouds.s3.blobstore.integration.S3ContainerIntegrationLiveTest;
|
||||||
|
import org.testng.SkipException;
|
||||||
import org.testng.annotations.AfterClass;
|
import org.testng.annotations.AfterClass;
|
||||||
import org.testng.annotations.Test;
|
import org.testng.annotations.Test;
|
||||||
|
|
||||||
|
@ -38,6 +39,7 @@ public final class JcloudsS3ContainerIntegrationLiveTest
|
||||||
"0"));
|
"0"));
|
||||||
private S3Proxy s3Proxy;
|
private S3Proxy s3Proxy;
|
||||||
private BlobStoreContext context;
|
private BlobStoreContext context;
|
||||||
|
private String blobStoreType;
|
||||||
|
|
||||||
@AfterClass
|
@AfterClass
|
||||||
public void tearDown() throws Exception {
|
public void tearDown() throws Exception {
|
||||||
|
@ -58,6 +60,7 @@ public final class JcloudsS3ContainerIntegrationLiveTest
|
||||||
info = TestUtils.startS3Proxy();
|
info = TestUtils.startS3Proxy();
|
||||||
s3Proxy = info.getS3Proxy();
|
s3Proxy = info.getS3Proxy();
|
||||||
context = info.getBlobStore().getContext();
|
context = info.getBlobStore().getContext();
|
||||||
|
blobStoreType = context.unwrap().getProviderMetadata().getId();
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw Throwables.propagate(e);
|
throw Throwables.propagate(e);
|
||||||
}
|
}
|
||||||
|
@ -70,4 +73,12 @@ public final class JcloudsS3ContainerIntegrationLiveTest
|
||||||
props.setProperty(Constants.PROPERTY_STRIP_EXPECT_HEADER, "true");
|
props.setProperty(Constants.PROPERTY_STRIP_EXPECT_HEADER, "true");
|
||||||
return props;
|
return props;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void testListMarkerAfterLastKey() throws Exception {
|
||||||
|
if (Quirks.OPAQUE_MARKERS.contains(blobStoreType)) {
|
||||||
|
throw new SkipException("opaque markers not supported");
|
||||||
|
}
|
||||||
|
super.testListMarkerAfterLastKey();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Ładowanie…
Reference in New Issue