Skip to content

Commit 01e474f

Browse files
committed
refactor(ci): split aws-tests.yml into per-domain workflow files
Split the monolithic aws-tests.yml (441 lines) into 5 focused files following the terragrunt repo's pattern of granular workflows: - terraform-tests.yml: terraform module tests (tf/tofu matrix) - aws-integration-tests.yml: AWS integration tests (test/ with -tags aws) - terragrunt-tests.yml: terragrunt module tests (tf/tofu matrix) - k8s-tests.yml: kubernetes + helm tests (shared minikube dependency) - build-and-release.yml: cross-compile builds + release upload Job definitions are unchanged — only reorganized into separate files. Release job keeps needs: build only, since test jobs are skipped on release events and tests already gate via push/PR triggers.
1 parent 4da0f24 commit 01e474f

6 files changed

Lines changed: 442 additions & 441 deletions

File tree

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: AWS Integration Tests
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
workflow_dispatch:
8+
9+
jobs:
10+
aws-integration-tests:
11+
name: AWS Integration Tests
12+
if: >-
13+
github.event_name != 'pull_request' ||
14+
github.event.pull_request.head.repo.full_name == github.repository
15+
runs-on: ubuntu-latest
16+
timeout-minutes: 60
17+
permissions:
18+
id-token: write
19+
contents: read
20+
21+
steps:
22+
- uses: actions/checkout@v4
23+
24+
- name: Install mise
25+
uses: jdx/mise-action@v3
26+
with:
27+
version: 2025.12.10
28+
experimental: true
29+
env:
30+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
31+
32+
- name: Go module cache
33+
uses: actions/cache@v4
34+
with:
35+
path: |
36+
~/go/pkg/mod
37+
~/.cache/go-build
38+
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
39+
restore-keys: |
40+
${{ runner.os }}-go-
41+
42+
- name: Download Go modules
43+
run: go mod download
44+
45+
- name: Configure AWS credentials
46+
uses: aws-actions/configure-aws-credentials@v4
47+
with:
48+
role-to-assume: arn:aws:iam::087285199408:role/terratest-gha
49+
aws-region: us-east-1
50+
51+
- name: Run AWS integration tests
52+
run: |
53+
mkdir -p /tmp/logs
54+
go test -v -p 1 -tags aws -count=1 -timeout 45m ./test/... 2>&1 | tee /tmp/logs/test_output.log
55+
56+
- name: Upload test logs
57+
if: always()
58+
uses: actions/upload-artifact@v4
59+
with:
60+
name: aws-integration-test-logs
61+
path: /tmp/logs/
62+
retention-days: 14

0 commit comments

Comments
 (0)