chore(compat): run the partition nightly in GovCloud and EUSC too (#5616)

The partition compatibility nightly ran the Java SDK suite in cn-north-1
only. GovCloud (IAM signs us-gov-west-1, no CloudFront) and EUSC (no
global endpoints) take their own code paths and had no end-to-end check.
The job is now a matrix of cn-north-1, us-gov-west-1 and eusc-de-east-1;
a dispatch that names a region runs that region alone.

Measured locally on main 367ae0b2d with a JVM image: a us-east-1 control
run and one run per new region, 2461 tests each. Beyond the control
run's one failure, GovCloud showed one and EUSC four, all in tests that
assumed the commercial partition, so they are fixed here and both new
allowlists start empty:

- WafV2Test.cloudfrontScopeIsolated created a CLOUDFRONT-scope IP set,
  which Floci refuses where CloudFront does not exist. It now runs only
  in the partitions that have CloudFront.
- S3Test built its LocationConstraint through the SDK enum, which has no
  value for eusc-de-east-1 and is then sent as the literal "null". It
  passes the region id as a string.

The workflow checks the suite out at the commit the nightly image was
built from, so the new legs first run with these fixes on the nightly
after this lands.

Signed-off-by: Hector Ventura <hectorvent@gmail.com>
This commit is contained in:
Hector Ventura authored and GitHub committed 2026-10-13 23:58:24 -04:00
1 parent d84a764cf9
commit d3999ad416
5 files changed
+34 -11

No files matched your search

@@ -62,9 +62,11 @@ class S3Test {
private static final String BUCKET = "sdk-test-bucket";
private static final String LOCATED_BUCKET = "sdk-test-bucket-located";
// Only the us-east-1 endpoint creates a bucket in another region; any other endpoint takes its own.
private static final BucketLocationConstraint LOCATION = TestFixtures.region().id().equals("us-east-1")
? BucketLocationConstraint.EU_CENTRAL_1
: BucketLocationConstraint.fromValue(TestFixtures.region().id());
// A string, not the SDK enum: the enum has no value for the ISO and EUSC regions, and an unknown
// one would be sent as the literal "null".
private static final String LOCATION = TestFixtures.region().id().equals("us-east-1")
? "eu-central-1"
: TestFixtures.region().id();
private static final String KEY = "test-file.txt";
private static final String CONTENT = "Hello from AWS SDK v2!";
@@ -112,7 +114,7 @@ class S3Test {
GetBucketLocationResponse response = s3.getBucketLocation(
GetBucketLocationRequest.builder().bucket(LOCATED_BUCKET).build());
assertThat(response.locationConstraint()).isEqualTo(LOCATION);
assertThat(response.locationConstraintAsString()).isEqualTo(LOCATION);
}
@Test
@@ -159,6 +159,8 @@ class WafV2Test {
@Test
@Order(9)
void cloudfrontScopeIsolated() {
Assumptions.assumeTrue(List.of("aws", "aws-cn").contains(TestFixtures.partition()),
"the CLOUDFRONT scope exists only in the partitions that have CloudFront");
waf.createIPSet(r -> r
.name(ipSetName).scope(Scope.CLOUDFRONT)
.ipAddressVersion(IPAddressVersion.IPV4)