Skip to content

Commit

Permalink
split out tests
Browse files Browse the repository at this point in the history
suspect customer connect blocking
  • Loading branch information
laidbackware authored Feb 20, 2024
1 parent 16690b8 commit fe9136b
Showing 1 changed file with 37 additions and 2 deletions.
39 changes: 37 additions & 2 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,45 @@ env:
GOPROXY: direct

jobs:
tests:
# Breaking tests into 2 phases, to prevent account lock out due to DOS protection
tests-1:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, macos-14, windows-latest]
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.21.4

- name: Checkout Code
uses: actions/checkout@v4

- name: Run Golang Tests
run: go test -v ./...

- name: Setup BATS
if: runner.os != 'windows'
run: |
set -e
if [ -n "$GITHUB_RUN_ID" ]; then
export GITHUB_API_TOKEN="${{ secrets.GITHUB_TOKEN }}"
fi
git clone https://github.com/bats-core/bats-core.git && bats-core/install.sh $HOME
- name: Run BATS Tests
if: runner.os != 'windows'
run: |
export PATH=${PATH}:/home/runner/bin
# Retry hack to attempt test 3 times
bats test/bats
tests-2:
strategy:
matrix:
os: [macos-14, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Set up Go
Expand Down

0 comments on commit fe9136b

Please sign in to comment.