Skip to content

Commit 386d79c

Browse files
committed
Inline verify failure check. Add a test_analyze_project_cache_hit
1 parent 15a62c2 commit 386d79c

File tree

2 files changed

+15
-32
lines changed

2 files changed

+15
-32
lines changed

.github/actions/verify_expected_failure/action.yml

Lines changed: 0 additions & 20 deletions
This file was deleted.

.github/workflows/test_actions.yml

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -238,30 +238,33 @@ jobs:
238238
continue-on-error: true
239239
with:
240240
project-directory: ${{ github.workspace }}/.github/test_projects/ni-python-styleguide-errors
241-
- name: Verify expected failure
242-
uses: ./.github/actions/verify_expected_failure
243-
with:
244-
step-outcome: ${{ steps.analyze-ni-python-styleguide-errors.outcome }}
241+
- name: Error if the previous step didn't fail
242+
if: steps.analyze-ni-python-styleguide-errors.outcome != 'failure'
243+
run: |
244+
echo "::error title=Test Failure::The previous step did not fail as expected."
245+
exit 1
245246
- name: Analyze mypy-errors project
246247
uses: ./analyze-project
247248
id: analyze-mypy-errors
248249
continue-on-error: true
249250
with:
250251
project-directory: ${{ github.workspace }}/.github/test_projects/mypy-errors
251-
- name: Verify expected failure
252-
uses: ./.github/actions/verify_expected_failure
253-
with:
254-
step-outcome: ${{ steps.analyze-mypy-errors.outcome }}
252+
- name: Error if the previous step didn't fail
253+
if: steps.analyze-mypy-errors.outcome != 'failure'
254+
run: |
255+
echo "::error title=Test Failure::The previous step did not fail as expected."
256+
exit 1
255257
- name: Analyze pyright-errors project
256258
uses: ./analyze-project
257259
id: analyze-pyright-errors
258260
continue-on-error: true
259261
with:
260262
project-directory: ${{ github.workspace }}/.github/test_projects/pyright-errors
261-
- name: Verify expected failure
262-
uses: ./.github/actions/verify_expected_failure
263-
with:
264-
step-outcome: ${{ steps.analyze-pyright-errors.outcome }}
263+
- name: Error if the previous step didn't fail
264+
if: steps.analyze-pyright-errors.outcome != 'failure'
265+
run: |
266+
echo "::error title=Test Failure::The previous step did not fail as expected."
267+
exit 1
265268
- name: Analyze only-ni-python-styleguide project
266269
uses: ./analyze-project
267270
with:

0 commit comments

Comments
 (0)