diff --git a/services/s3/src/test/java/software/amazon/awssdk/services/s3/EndpointOverrideEndpointResolutionTest.java b/services/s3/src/test/java/software/amazon/awssdk/services/s3/EndpointOverrideEndpointResolutionTest.java index 22fc9770446a..013917270961 100644 --- a/services/s3/src/test/java/software/amazon/awssdk/services/s3/EndpointOverrideEndpointResolutionTest.java +++ b/services/s3/src/test/java/software/amazon/awssdk/services/s3/EndpointOverrideEndpointResolutionTest.java @@ -230,14 +230,13 @@ public static Collection testCases() { .setExpectedSigningServiceName("s3") .setExpectedSigningRegion(Region.US_WEST_2)); - //FIXME: The ruleset is currently broken for this test case. The provider is not preserving the path part - // cases.add(new TestCase().setCaseName("access point with http, path, query, and port") - // .setGetObjectBucketName("arn:aws:s3:us-west-2:123456789012:accesspoint:myendpoint") - // .setEndpointUrl("http://beta.example.com:1234/path?foo=bar") - // .setClientRegion(Region.US_WEST_2) - // .setExpectedEndpoint("http://myendpoint-123456789012.beta.example.com:1234/path/object?foo=bar") - // .setExpectedSigningServiceName("s3") - // .setExpectedSigningRegion(Region.US_WEST_2)); + cases.add(new TestCase().setCaseName("access point with http, path, query, and port") + .setGetObjectBucketName("arn:aws:s3:us-west-2:123456789012:accesspoint:myendpoint") + .setEndpointUrl("http://beta.example.com:1234/path?foo=bar") + .setClientRegion(Region.US_WEST_2) + .setExpectedEndpoint("http://myendpoint-123456789012.beta.example.com:1234/path/object?foo=bar") + .setExpectedSigningServiceName("s3") + .setExpectedSigningRegion(Region.US_WEST_2)); cases.add(new TestCase().setCaseName("outposts access point") .setGetObjectBucketName("arn:aws:s3-outposts:us-west-2:123456789012:outpost:op-01234567890123456:accesspoint:myaccesspoint") @@ -313,15 +312,14 @@ public static Collection testCases() { .setExpectedSigningServiceName("s3") .setExpectedSigningRegion(Region.US_WEST_2)); - //FIXME: The ruleset is currently broken for this test case. The provider is not preserving the path part - // cases.add(new TestCase().setCaseName("access point with http, path, query, port, different arn region, and arn region enabled") - // .setGetObjectBucketName("arn:aws:s3:us-west-2:123456789012:accesspoint:myendpoint") - // .setEndpointUrl("http://accesspoint.vpce-123-abc.s3.us-west-2.vpce.amazonaws.com:1234/path?foo=bar") - // .setS3Configuration(c -> c.useArnRegionEnabled(true)) - // .setClientRegion(Region.EU_WEST_1) - // .setExpectedEndpoint("http://myendpoint-123456789012.accesspoint.vpce-123-abc.s3.us-west-2.vpce.amazonaws.com:1234/path/object?foo=bar") - // .setExpectedSigningServiceName("s3") - // .setExpectedSigningRegion(Region.US_WEST_2)); + cases.add(new TestCase().setCaseName("access point with http, path, query, port, different arn region, and arn region enabled") + .setGetObjectBucketName("arn:aws:s3:us-west-2:123456789012:accesspoint:myendpoint") + .setEndpointUrl("http://accesspoint.vpce-123-abc.s3.us-west-2.vpce.amazonaws.com:1234/path?foo=bar") + .setS3Configuration(c -> c.useArnRegionEnabled(true)) + .setClientRegion(Region.EU_WEST_1) + .setExpectedEndpoint("http://myendpoint-123456789012.accesspoint.vpce-123-abc.s3.us-west-2.vpce.amazonaws.com:1234/path/object?foo=bar") + .setExpectedSigningServiceName("s3") + .setExpectedSigningRegion(Region.US_WEST_2)); cases.add(new TestCase().setCaseName("outposts access point with dual stack enabled via s3 config") .setGetObjectBucketName("arn:aws:s3-outposts:us-west-2:123456789012:outpost:op-01234567890123456:accesspoint:myaccesspoint")