Skip to content

Commit

Permalink
Merge pull request #61 from kubescape/test-parallelism
Browse files Browse the repository at this point in the history
adding go-test-split-action
  • Loading branch information
matthyx authored Feb 23, 2024
2 parents 6e35084 + 2a13a44 commit 23ba4ab
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 9 deletions.
36 changes: 29 additions & 7 deletions .github/workflows/pr-created.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,40 @@ jobs:
GO_VERSION: "1.21"
CGO_ENABLED: 0
secrets: inherit

component-tests:
runs-on: ubuntu-latest
strategy:
matrix:
test: [
"TestSynchronizer_TC01_InCluster",
"TestSynchronizer_TC01_Backend",
"TestSynchronizer_TC02_InCluster",
"TestSynchronizer_TC02_Backend",
"TestSynchronizer_TC04_InCluster",
"TestSynchronizer_TC04_Backend",
"TestSynchronizer_TC05_InCluster",
"TestSynchronizer_TC05_Backend",
"TestSynchronizer_TC06",
"TestSynchronizer_TC07",
"TestSynchronizer_TC08",
"TestSynchronizer_TC09",
"TestSynchronizer_TC10",
"TestSynchronizer_TC11",
"TestSynchronizer_TC12"
]
steps:
- uses: actions/checkout@v4
- name: Set up Go 1.21
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Go
env:
CGO_ENABLED: 0
uses: actions/setup-go@v4
with:
go-version: "1.21"
env: |
CGO_ENABLED=0
- name: Run component tests

- name: Run test
run: |
echo "machine github.com login git password ${{ secrets.INGESTERS_READ_TOKEN }}" > ~/.netrc
cd tests && go test --timeout=20m --tags=integration ./...
cd tests && go test ./... -run ${{ matrix.test }} --timeout=20m --tags=integration
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,3 @@
# Dependency directories (remove the comment below to include it)
# vendor/

# Go workspace file
go.work

0 comments on commit 23ba4ab

Please sign in to comment.