Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 6 additions & 8 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,8 @@ name: Test SimBank
on:
# This workflow_call is used after the Main Build of Simplatform.
workflow_call:
# This workflow_dispatch allows this workflow to be called by a
# scheduled regression run in the Automation repository. It also
# allows this workflow to be called by pressing 'Run Workflow'.
workflow_dispatch:
schedule:
- cron: "0 6 * * *" # Daily at 06:00

env:
NAMESPACE: ${{ github.repository_owner }}
Expand Down Expand Up @@ -101,7 +99,7 @@ jobs:

# If this workflow was called by the daily regression test run, build the code.
- name: Build SimBank using local build script
if: ${{ github.event_name == 'workflow_dispatch' }}
if: ${{ github.event_name == 'schedule' }}
run: |
./build-locally.sh --skip-docker --skip-secrets

Expand Down Expand Up @@ -157,15 +155,15 @@ jobs:
# Skip these steps for forks. Only report results if this workflow was
# called from a regression run as Main builds run multiple times a day.
- name: Combine test reports
if: ${{ github.repository_owner == 'galasa-dev' && github.event_name == 'workflow_dispatch' }}
if: ${{ github.repository_owner == 'galasa-dev' && github.event_name == 'schedule' }}
run: |
jq -s '{ tests: map(.tests[]) }' ${{ github.workspace }}/.galasa/test-1.json ${{ github.workspace }}/.galasa/test-2.json ${{ github.workspace }}/.galasa/test-3.json > ${{ github.workspace }}/.galasa/tests.json

# The test report must be sent to Slack in the next job that uses the ubuntu-latest runner.
# We need to run a Docker image to communicate with the Slack webhook and the macos-latest
# runner does not have `docker` installed. Upload the report and download in the next job.
- name: Upload combined test report
if: ${{ github.repository_owner == 'galasa-dev' && github.event_name == 'workflow_dispatch' }}
if: ${{ github.repository_owner == 'galasa-dev' && github.event_name == 'schedule' }}
uses: actions/upload-artifact@v4
with:
name: tests.json
Expand All @@ -177,7 +175,7 @@ jobs:

# Skip this job for forks. Only report results if this workflow was
# called from a regression run as Main builds run multiple times a day.
if: ${{ github.repository_owner == 'galasa-dev' && github.event_name == 'workflow_dispatch' }}
if: ${{ github.repository_owner == 'galasa-dev' && github.event_name == 'schedule' }}

needs: [build-and-run-simbank-tests]

Expand Down