* ci(compat): run the Terraform and OpenTofu bats files concurrently
compat-terraform is the slowest leg of the compatibility workflow and the job
that ends it: its test step is flat at 13m18s to 13m32s across recent runs, while
every other leg finishes several minutes earlier. The six bats files ran as a
single `bats test/` process, so they executed one after another even though each
is an independent root module with its own state and identifiers.
Their cost is dominated by the AWS provider's own waiters rather than by floci:
Neptune and ElastiCache sleep 30s before the first poll on create and delete, and
RDS sleeps 60s. Nothing can shorten those, only overlap them.
Each test/*.bats file now runs in its own process, reaped with wait, writing one
junit-<file>.xml. bats' own --jobs needs GNU parallel or rush, neither of which is
in the image, so the files are forked directly. Output is collected per file and
replayed in a fixed order, because six interleaved streams are unreadable.
BATS_PARALLEL_FILES=0 restores sequential execution for isolating a failure. Both
run.sh wrappers and the justfile recipes delegate to the same runner, so a local
run and a CI run execute identical logic.
The provider plugin cache is warmed once before forking: every fixture deletes its
lock file in setup_file and the AWS provider unpacks to 770 MB, so six concurrent
inits would otherwise pull about 4.6 GB. The warm-up is sequential because that
cache is safe for concurrent readers but not writers, and a failure there is
logged and tolerated rather than fatal.
Also adds the .dockerignore both suites were missing. Each directory can hold a
local .terraform/ of several hundred megabytes plus stray state, none of which
exists in a CI checkout, so image builds were copying roughly 1.4 GB of host state
and behaving differently from CI.
Measured locally on the same image, all 84 tests passing either way: sequential
1130s, concurrent 260s.
* ci(compat): clear stale JUnit reports before running the suites
The runner created the results directory but never cleared it, and the per-file
reports do not replace everything an earlier run could have left: a renamed or
removed bats file keeps its old XML, and so does a run that stops before writing
all of them. Every consumer globs the directory, so those linger in the summary.
CI never saw this, since it starts from a fresh checkout with an empty
test-results. Locally the directory persists in the working tree, and the case is
already live: both suites still hold the single junit.xml the previous sequential
runner wrote, which the junit-<file>.xml names could never overwrite. A local run
mixed months-old results into the current ones, including in the timing numbers
this change was measured with.
Raised by the review on this PR.
* fix(compat): stop the report cleanup reaching other suites' results
The cleanup added in the previous commit globbed junit*.xml, which is wrong
wherever the results directory is shared. docker/run-docker-tests.sh mounts one
test-results directory for all eight suites and runs them in order, so the glob
deleted compat-terraform's six reports when compat-opentofu started, and both
suites deleted the junit.xml that sdk-test-awscli and compat-cdk had already
written. It destroyed results rather than tidying them.
The deletion now names the reports this run is about to write, taken from the
bats files already enumerated above it, so it cannot reach a filename this suite
does not own. That keeps the reason the cleanup exists, a run that stops before
rewriting every report leaving the survivors behind, without the reach.
One case is deliberately given up: a report whose bats file was renamed or
removed is no longer cleared, because nothing in the current run names it. A
lingering stale report is cosmetic; deleting another suite's results is not.
Raised by the review on this PR.
The Rust suite is dropped from the compatibility matrix: the suite
directory, its justfile recipes (test-rust, setup-rust, test-all and
setup aggregates), README rows, and gitignore entry. The Rust SDK client
example in the README stays since the wire protocols remain
language-agnostic.
The README compatibility table had also drifted ~33% behind the real
suites; counts are refreshed from the Jul 2 runtime totals (java 1326,
node 449, python 311, terraform 22, opentofu 16, cdk 20) and static
counts (go 157 subtests, awscli 205 bats tests), with the headline
updated from 1,969 to 2,506 tests across 5 SDKs and 3 IaC tools.
* test: move compatibility tests into this repo
* fix: add StatisticValues parsing to CloudWatchMetricsJsonHandler
* fix: add missing required abstract methods to EmulatorConfig in EventBridgeSchedulerIntegrationTest
* test: add sdk tests for multipart S3 copy coverage
* fix: cover and fix smithy cbor and multipart s3 copy regressions
* test: migrate more test coverage to new folder
* test: add missing ec2 expectation in healthcheck test
* docs: update READMEs in `./compatibility-tests`