From c94783327f601ebec155105ad1b80944c152a5f8 Mon Sep 17 00:00:00 2001 From: Ariel Mendelzon Date: Wed, 8 Nov 2023 01:26:17 +1300 Subject: [PATCH] Periodic unit and integration tests run workflow Scheduled to run every 24hs --- .github/workflows/periodic.yml | 22 ++++++++++++++++++++++ .github/workflows/run-tests.yml | 12 +++++++++++- 2 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/periodic.yml diff --git a/.github/workflows/periodic.yml b/.github/workflows/periodic.yml new file mode 100644 index 00000000..e6cf61f3 --- /dev/null +++ b/.github/workflows/periodic.yml @@ -0,0 +1,22 @@ +name: Periodic workflow run + +on: + push: + schedule: + - cron: "17 6 * * *" + +jobs: + run-tests-on-branches: + name: "Run tests on stable branches" + + strategy: + matrix: + branch: [master] + + uses: ${{ format("rsksmart/rsk-powhsm/.github/workflows/run-tests.yml@{0}", matrix.branch) }} + with: + branch: ${{ matrix.branch }} + secrets: inherit + + + diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index b1256536..4f2f9502 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -1,6 +1,13 @@ name: Run tests -on: [push] +on: + push: + workflow_call: + inputs: + branch: + description: "The branch on which to run this workflow" + required: true + type: string jobs: run-unit-tests: @@ -10,6 +17,8 @@ jobs: steps: - name: Checkout this repo uses: actions/checkout@v3 + with: + ref: ${{ inputs.branch }} - name: Build the middleware docker image run: docker/mware/build @@ -49,6 +58,7 @@ jobs: uses: actions/checkout@v3 with: path: rsk-powhsm + ref: ${{ inputs.branch }} - name: Build required software working-directory: rsk-powhsm