Skip to content

Commit 64946ed

Browse files
author
Anton
authored
Split integration tests to different jobs (#163)
1 parent c0d3d41 commit 64946ed

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed

.github/actions/int-test/action.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ inputs:
1010
ATLAS_PRIVATE_KEY:
1111
description: "Organization private API key"
1212
required: true
13+
TEST_NAME:
14+
description: "The name of the test to run"
15+
required: true
1316
runs:
1417
using: 'docker'
1518
image: 'Dockerfile'

.github/actions/int-test/entrypoint.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ export ATLAS_PRIVATE_KEY="${INPUT_ATLAS_PRIVATE_KEY}"
77
# otherwise we may get strange "Detected Programmatic Focus - setting exit status to 197"
88
export GINKGO_EDITOR_INTEGRATION="true"
99

10-
ginkgo -v -p -nodes=4 ./test/int
10+
ginkgo --focus "${INPUT_TEST_NAME}" -v -nodes=4 ./test/int

.github/workflows/test.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,13 @@ jobs:
2626
- name: Run testing
2727
run: CGO_ENABLED=0 go test -v $(go list ./pkg/...)
2828

29-
int-test:
29+
int-test-project:
3030
name: Integration tests
3131
runs-on: ubuntu-latest
32+
strategy:
33+
fail-fast: false
34+
matrix:
35+
test: [ "AtlasProject", "AtlasCluster", "AtlasDatabaseUser" ]
3236
steps:
3337
- uses: actions/[email protected]
3438

@@ -43,6 +47,7 @@ jobs:
4347
ATLAS_ORG_ID: ${{ secrets.ATLAS_ORG_ID }}
4448
ATLAS_PUBLIC_KEY: ${{ secrets.ATLAS_PUBLIC_KEY }}
4549
ATLAS_PRIVATE_KEY: ${{ secrets.ATLAS_PRIVATE_KEY }}
50+
TEST_NAME: ${{ matrix.test }}
4651

4752
prepare-e2e:
4853
name: Prepare E2E configuration and image

0 commit comments

Comments
 (0)