feat: openapi desired features #1029
Workflow file for this run
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
name: Integration tests | |
on: [pull_request] | |
jobs: | |
cypress-run: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Waiting for pages to change | |
uses: fountainhead/[email protected] | |
id: wait-for-pages-changed | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
ref: ${{ github.event.pull_request.head.sha || github.sha }} | |
checkName: 'Pages changed - elated-hoover-5c29bf' | |
timeoutSeconds: 3600 | |
- name: Waiting for 200 from the Netlify Preview | |
if: steps.wait-for-pages-changed.outputs.conclusion == 'neutral' | |
uses: jakepartusch/[email protected] | |
id: wait-for-netflify-preview | |
with: | |
site_name: 'elated-hoover-5c29bf' | |
max_timeout: 3600 | |
env: | |
NETLIFY_TOKEN: ${{ secrets.NETLIFY_TOKEN }} | |
- name: Fetch navigation.json | |
uses: wei/curl@v1 | |
with: | |
args: -o src/tests/cypress/fixtures/navigation.json https://developers.vtex.com/navigation.json | |
- name: Cypress run | |
uses: cypress-io/github-action@v5 | |
with: | |
browser: chrome | |
headed: true | |
env: | |
CYPRESS_baseUrl: ${{ steps.wait-for-netflify-preview.outputs.url }} | |
CYPRESS_testProbability: 0.1 | |
- name: Generate summary report | |
if: always() | |
run: | | |
touch src/tests/summary.md | |
if [[ -f "./cypress.log" ]]; then | |
node src/tests/utils/summary-report.js > src/tests/summary.md | |
rm cypress.log | |
fi | |
- name: Comment PR with summary report | |
if: always() | |
uses: thollander/actions-comment-pull-request@v2 | |
with: | |
comment_tag: tests-summary | |
filePath: src/tests/summary.md | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |