IEN-936 | BCCNM preview filter bug #862
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: PR Accessibility Checks | |
on: | |
pull_request: | |
paths: | |
- 'apps/api/**' | |
- 'apps/web/**' | |
- 'packages/common/**' | |
jobs: | |
pr-checks: | |
runs-on: ubuntu-latest | |
timeout-minutes: 20 | |
environment: | |
name: dev | |
steps: | |
- name: checkout | |
uses: actions/checkout@v3 | |
- name: setup node v18 | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18 | |
- uses: actions/cache@v3 | |
name: Cache yarn | |
with: | |
path: ./.yarn/cache | |
key: ${{ runner.os }}-yarn-${{ hashFiles('./yarn.lock') }} | |
restore-keys: ${{ runner.os }}-yarn-${{ hashFiles('./yarn.lock') }} | |
- name: Install PostgreSQL client | |
run: sudo apt-get update && sudo apt-get install -y postgresql-client | |
- name: Install dependencies | |
run: yarn install | |
- name: Run application and cypress/accessibility tests | |
run: make test-pa11y | |
env: | |
ENV_NAME: 'local' | |
E2E_TEST_USERNAME: '${{ secrets.E2E_TEST_USERNAME}}' | |
E2E_TEST_PASSWORD: '${{ secrets.E2E_TEST_PASSWORD}}' | |
AUTH_URL: 'http://localhost:8080' | |
AUTH_REALM: 'ien' | |
AUTH_CLIENTID: 'IEN' | |
NEXT_PUBLIC_API_URL: 'http://localhost:4000/api/v1' | |
NEXT_PUBLIC_AUTH_REALM: 'ien' | |
NEXT_PUBLIC_AUTH_CLIENTID: 'IEN' | |
NEXT_PUBLIC_AUTH_URL: 'http://localhost:8080' | |
- name: Generate markdown from test results | |
run: make generate-accessibility-results | |
if: ${{ failure() }} | |
- uses: actions/github-script@v6 | |
with: | |
github-token: ${{secrets.GITHUB_TOKEN}} | |
script: | | |
const fs = require('fs'); | |
const comment = fs.readFileSync('./packages/accessibility/out/accessibility_results.md', 'utf8'); | |
github.issues.createComment({ | |
issue_number: context.issue.number, | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
body: comment | |
}) | |
if: ${{ failure() }} |