From d2d54d1343fe236096cde75a6138c39cae432954 Mon Sep 17 00:00:00 2001 From: Martin McKeaveney Date: Tue, 29 Mar 2022 17:50:52 +0100 Subject: [PATCH] adding smoke test run on schedule, with discord webhook --- .github/workflows/smoke_test.yaml | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) diff --git a/.github/workflows/smoke_test.yaml b/.github/workflows/smoke_test.yaml index 745fed1306..b48d0b5722 100644 --- a/.github/workflows/smoke_test.yaml +++ b/.github/workflows/smoke_test.yaml @@ -2,6 +2,9 @@ name: Budibase Smoke Test on: workflow_dispatch: + schedule: + - cron: "0 5 * * *" # every day at 5AM + jobs: release: @@ -23,10 +26,13 @@ jobs: -o packages/builder/cypress.env.json \ -L https://api.github.com/repos/budibase/budibase-infra/contents/test/cypress.env.json wc -l packages/builder/cypress.env.json - - run: yarn test:e2e:ci - env: - CI: true - name: Budibase CI + + - name: Cypress run + id: cypress + uses: cypress-io/github-action@v2 + with: + install: false + command: yarn test:e2e:ci # TODO: upload recordings to s3 # - name: Configure AWS Credentials @@ -36,11 +42,11 @@ jobs: # aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} # aws-region: eu-west-1 - # TODO look at cypress reporters - # - name: Discord Webhook Action - # uses: tsickert/discord-webhook@v4.0.0 - # with: - # webhook-url: ${{ secrets.PROD_DEPLOY_WEBHOOK_URL }} - # content: "Production Deployment Complete: ${{ env.RELEASE_VERSION }} deployed to Budibase Cloud." - # embed-title: ${{ env.RELEASE_VERSION }} + - name: Discord Webhook Action + uses: tsickert/discord-webhook@v4.0.0 + with: + webhook-url: ${{ secrets.BUDI_QA_WEBHOOK }} + content: "Smoke test run completed with ${{ steps.cypress.outcome }}. See results at ${{ steps.cypress.dashboardUrl }}" + embed-title: ${{ steps.cypress.outcome }} + embed-color: ${{ steps.cypress.outcome == "success" && '3066993' || '15548997' }}