Skip to content

Commit

Permalink
fixing tests.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
kessler-frost committed Jan 30, 2024
1 parent d0f494d commit 6be391d
Showing 1 changed file with 13 additions and 18 deletions.
31 changes: 13 additions & 18 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ on:
commit_sha:
description: "Commit SHA used for testing. If left blank, the default branch will be used."
type: string
default: ""
required: false

jobs:
Expand Down Expand Up @@ -67,7 +68,7 @@ jobs:
codecov: ${{ steps.local-codecov.outputs.local_codecov }}
steps:
- name: Check out the default branch
if: github.event_name != 'workflow_dispatch' || github.event.inputs.commit_sha == ''
if: github.event_name != 'workflow_dispatch' || github.event.inputs.commit_sha == ""
uses: actions/checkout@v4
with:
persist-credentials: false
Expand Down Expand Up @@ -305,19 +306,16 @@ jobs:
npm test -- --coverage --watchAll=false --maxWorkers=50%
- name: Dump Covalent logs
if: >
steps.covalent_start.outcome == 'success'
&& failure()
run: covalent logs

- name: Upload SDK report to Codecov
id: upload-sdk-report
if: >
env.RECOMMENDED_PLATFORM
&& github.event_name != 'workflow_dispatch'
&& (github.event_name == 'schedule'
|| github.event_name == 'workflow_dispatch'
|| steps.sdk-coverage.outcome == 'success')
uses: AgnostiqHQ/covalent/.github/workflows/upload_to_codecov_with_retry.yml@develop
uses: ./.github/workflows/upload_to_codecov_with_retry.yml
with:
files: ./sdk_coverage.xml
flags: SDK
Expand All @@ -328,10 +326,10 @@ jobs:
id: upload-dispatcher-report
if: >
env.RECOMMENDED_PLATFORM
&& github.event_name != 'workflow_dispatch'
&& (github.event_name == 'schedule'
|| github.event_name == 'workflow_dispatch'
|| steps.dispatcher-coverage.outcome == 'success')
uses: AgnostiqHQ/covalent/.github/workflows/upload_to_codecov_with_retry.yml@develop
uses: ./.github/workflows/upload_to_codecov_with_retry.yml
with:
files: ./dispatcher_coverage.xml
flags: Dispatcher
Expand All @@ -342,9 +340,8 @@ jobs:
id: upload-functional-report
if: >
env.RECOMMENDED_PLATFORM
&& github.event_name != 'workflow_dispatch'
&& steps.functional-coverage.outcome == 'success'
uses: AgnostiqHQ/covalent/.github/workflows/upload_to_codecov_with_retry.yml@develop
uses: ./.github/workflows/upload_to_codecov_with_retry.yml
with:
files: ./functional_tests_coverage.xml
flags: Functional_Tests
Expand All @@ -355,10 +352,10 @@ jobs:
id: upload-ui-backend-report
if: >
env.RECOMMENDED_PLATFORM
&& github.event_name != 'workflow_dispatch'
&& (github.event_name == 'schedule'
|| github.event_name == 'workflow_dispatch'
|| steps.ui-backend-coverage.outcome == 'success')
uses: AgnostiqHQ/covalent/.github/workflows/upload_to_codecov_with_retry.yml@develop
uses: ./.github/workflows/upload_to_codecov_with_retry.yml
with:
files: ./ui_backend_coverage.xml
flags: UI_Backend
Expand All @@ -369,10 +366,10 @@ jobs:
id: upload-ui-frontend-report
if: >
env.RECOMMENDED_PLATFORM
&& github.event_name != 'workflow_dispatch'
&& (github.event_name == 'schedule'
|| github.event_name == 'workflow_dispatch'
|| steps.ui-frontend-tests.outcome == 'success')
uses: AgnostiqHQ/covalent/.github/workflows/upload_to_codecov_with_retry.yml@develop
uses: ./.github/workflows/upload_to_codecov_with_retry.yml
with:
files: ./covalent_ui/webapp/coverage/clover.xml
flags: UI_Frontend
Expand All @@ -396,14 +393,12 @@ jobs:
echo "::set-output name=local_codecov::${local_codecov}"
- name: Alert Slack
if: >
github.event_name == 'schedule'
&& failure()
if: failure()
uses: rtCamp/action-slack-notify@v2
env:
SLACK_CHANNEL: "covalent-ci"
SLACK_USERNAME: "CovalentOpsBot"
SLACK_MESSAGE: "The tests.yml workflow is failing in develop!"
SLACK_MESSAGE: "The tests.yml workflow is failing in the last '${{github.event_name}}' event run!"
SLACK_COLOR: ${{ job.status }}
SLACK_TITLE: ":warning: Attention Required :warning:"
SLACK_WEBHOOK: ${{ secrets.SLACK_ALERT_WEBHOOK }}
Expand Down

0 comments on commit 6be391d

Please sign in to comment.