-
-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (43 loc) · 1.22 KB
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: Run Tests
on:
pull_request:
types: [opened, synchronize, reopened]
paths-ignore:
- "README.md"
release:
types: [created]
workflow_dispatch:
permissions:
id-token: write # This is required for requesting the JWT for OIDC
contents: read # This is required for actions/checkout
jobs:
test:
name: Run Tests
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: "./go.mod"
id: go
- name: Setup Terraform
uses: hashicorp/setup-terraform@v3
with:
terraform_wrapper: false
- name: Setup atmos
uses: cloudposse/github-action-setup-atmos@v2
with:
install-wrapper: false
- name: Get dependencies
run: go mod download
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: arn:aws:iam::799847381734:role/cptest-test-gbl-sandbox-tester
role-session-name: githubaction-test-repo-terratest-helpers
aws-region: us-east-2
- name: Run tests
run: |
go test ./...