From ba08c57156acf1d3e320f3cd4d2fd10c3855a958 Mon Sep 17 00:00:00 2001 From: diamondburned Date: Sat, 4 Nov 2023 02:49:39 -0700 Subject: [PATCH] *: Run only short integration tests in CI by default --- .github/workflows/test.yml | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index eeb67a1..523bb11 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -3,6 +3,13 @@ name: Test on: push: pull_request: + workflow_dispatch: + inputs: + short-integration-test: + description: 'Run only the short integration tests' + required: false + default: true + type: boolean jobs: nix-env: @@ -75,13 +82,14 @@ jobs: - name: Test run: | - go test -coverprofile /tmp/coverage.out -race ./... + go test -coverprofile /tmp/coverage.out -race $TEST_FLAGS ./... go tool cover -func /tmp/coverage.out env: - BOT_TOKEN: ${{ secrets.BOT_TOKEN }} + TEST_FLAGS: -short=${{ github.event.inputs.short-integration-test }} CHANNEL_ID: ${{ secrets.CHANNEL_ID }} GUILD_ID: ${{ secrets.GUILD_ID }} VOICE_ID: ${{ secrets.VOICE_ID }} + BOT_TOKEN: ${{ secrets.BOT_TOKEN }} - name: Upload coverage profile uses: actions/upload-artifact@v3