-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ability to skip tests when doing workflow dispatch (#706)
- Loading branch information
Showing
1 changed file
with
6 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,7 +11,7 @@ on: | |
run-tests: | ||
description: "Run tests step" | ||
required: false | ||
default: false | ||
default: true | ||
type: boolean | ||
|
||
push: | ||
|
@@ -527,7 +527,7 @@ jobs: | |
IMAGE_TAG: ${{ needs.build.outputs.image_version }} | ||
|
||
- name: Helmfile apply pytest | ||
# if: github.event.review.state == 'approved' || github.event_name == 'push' || ( github.event.inputs.run-reset-deployments == 'true' && github.event.inputs.run-tests == 'true' ) || github.event.inputs.run-tests == 'true' | ||
if: ${{ github.event_name != 'workflow_dispatch' || (github.event_name == 'workflow_dispatch' && github.event.inputs.run-tests != 'false') }} | ||
id: pytest | ||
uses: helmfile/[email protected] | ||
with: | ||
|
@@ -547,7 +547,7 @@ jobs: | |
IMAGE_TAG: ${{ needs.build.outputs.image_version }} | ||
|
||
- name: Wait for pytest and print logs | ||
# if: github.event.review.state == 'approved' || github.event_name == 'push' || ( github.event.inputs.run-reset-deployments == 'true' && github.event.inputs.run-tests == 'true' ) || github.event.inputs.run-tests == 'true' | ||
if: ${{ github.event_name != 'workflow_dispatch' || (github.event_name == 'workflow_dispatch' && github.event.inputs.run-tests != 'false') }} | ||
run: | | ||
while true; do | ||
# Check if the job is complete or failed | ||
|
@@ -578,7 +578,7 @@ jobs: | |
NAMESPACE: dev-cloudapi | ||
|
||
- name: Copy k8s pytest results | ||
# if: github.event.review.state == 'approved' || github.event_name == 'push' || ( github.event.inputs.run-reset-deployments == 'true' && github.event.inputs.run-tests == 'true' ) || github.event.inputs.run-tests == 'true' | ||
if: ${{ github.event_name != 'workflow_dispatch' || (github.event_name == 'workflow_dispatch' && github.event.inputs.run-tests != 'false') }} | ||
run: | | ||
echo "apiVersion: v1 | ||
kind: Pod | ||
|
@@ -625,15 +625,15 @@ jobs: | |
|
||
- name: Publish Test Report | ||
uses: mikepenz/action-junit-report@v4 | ||
if: always() | ||
if: ${{ github.event_name != 'workflow_dispatch' || (github.event_name == 'workflow_dispatch' && github.event.inputs.run-tests != 'false') }} | ||
with: | ||
report_paths: "./test_output.xml" | ||
fail_on_failure: true | ||
detailed_summary: true | ||
require_passed_tests: true | ||
|
||
- name: Pytest coverage comment | ||
if: github.event_name == 'pull_request' | ||
if: ${{ github.event_name != 'workflow_dispatch' || (github.event_name == 'workflow_dispatch' && github.event.inputs.run-tests != 'false') }} | ||
uses: MishaKav/[email protected] | ||
with: | ||
pytest-coverage-path: ./test_coverage.txt | ||
|