Skip to content

Commit

Permalink
chore: smol cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
kanadgupta committed Dec 4, 2024
1 parent 8d815be commit f452ff7
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,21 +88,21 @@ jobs:
with:
rdme: openapi validate "oas-examples-repo/3.1/json/petstore.json"

- name: Run `openapi validate` on a file that will fail
- name: Run `openapi validate` on an invalid file
uses: ./rdme-repo/
id: openapi-validate-fail
continue-on-error: true
with:
rdme: openapi validate rdme-repo/__tests__/__fixtures__/invalid-oas.json

- name: Assert previous step failed
if: ${{ steps.openapi-validate-fail.outcome == 'success' }}
run: echo "::error::Expected previous workflow step to fail" && exit 1

- name: Echo previous step failed
- name: Assert that previous validation step failed
if: ${{ steps.openapi-validate-fail.outcome == 'failure' }}
run: echo "The previous step failed as expected."

- name: Throw error if previous validation step did not fail
if: ${{ steps.openapi-validate-fail.outcome == 'success' }}
run: echo "::error::Expected previous workflow step to fail" && exit 1

# Docs: https://rdme-test.readme.io
- name: Run `openapi` command
uses: ./rdme-repo/
Expand Down

0 comments on commit f452ff7

Please sign in to comment.