Skip to content

Commit

Permalink
setup local env for paywright tests
Browse files Browse the repository at this point in the history
Signed-off-by: Ivan Milchev <[email protected]>
  • Loading branch information
imilchev committed Aug 9, 2022
1 parent 227d28e commit dab0821
Showing 1 changed file with 51 additions and 0 deletions.
51 changes: 51 additions & 0 deletions .github/workflows/check-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,3 +80,54 @@ jobs:
service_account_credentials: ${{ secrets.MONDOO_SECRET }}
scan_type: k8s
path: prod-manifests.yaml

run-playwright:
name: Run Playwright
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
path: './frontend'

- name: Checkout
uses: actions/checkout@v3
with:
repository: podkrepi-bg/api
ref: master
path: './api'

- name: Run db
working-directory: ./api
run: docker compose up -d pg-db

- name: Run api
working-directory: ./api
run: docker compose up -d --force-recreate --no-build migrate-db seed-db api keycloak

- uses: actions/setup-node@v2
with:
node-version: '14.x'

- name: Install dependencies
run: yarn

- name: Install Playwright Browsers
run: npx playwright install --with-deps

- name: Run Playwright tests
run: yarn playwright test e2e/local

- uses: actions/upload-artifact@v2
if: always()
with:
name: playwright-report
path: playwright-report/
retention-days: 30

- name: Setup upterm session
uses: lhotari/action-upterm@v1
with:
## limits ssh access and adds the ssh public key for the user which triggered the workflow
limit-access-to-actor: true
## limits ssh access and adds the ssh public keys of the listed GitHub users
limit-access-to-users: imilchev

0 comments on commit dab0821

Please sign in to comment.