mirror of
https://github.com/nowcommunity/nowdatabase.git
synced 2026-10-12 19:13:52 +03:00
42 lines
892 B
YAML
42 lines
892 B
YAML
name: 'End-to-end tests'
|
|
|
|
on:
|
|
pull_request:
|
|
types: [opened, reopened, synchronize]
|
|
branches:
|
|
- '**'
|
|
|
|
jobs:
|
|
e2e_tests:
|
|
name: 'End-to-end tests'
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup node
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: 20
|
|
|
|
- name: Create env-files
|
|
env:
|
|
GEONAMES_USERNAME: ${{ secrets.GEONAMES_USERNAME }}
|
|
run: GEONAMES_USERNAME=$GEONAMES_USERNAME npm run config
|
|
|
|
- name: Install root dependencies
|
|
run: npm ci
|
|
|
|
- name: 'Start containers'
|
|
run: npm run start:anon -- --wait -d
|
|
|
|
- name: Run e2e tests
|
|
uses: cypress-io/github-action@v6
|
|
with:
|
|
browser: chrome
|
|
|
|
- name: Dump docker logs on failure
|
|
if: failure()
|
|
uses: jwalton/gh-docker-logs@v2
|