Skip to content

Commit

Permalink
Run test server for e2e tests in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
lruozzi9 committed Feb 6, 2024
1 parent 8441e74 commit 359a23d
Showing 1 changed file with 19 additions and 6 deletions.
25 changes: 19 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
- 'dependabot/**'
pull_request: ~
release:
types: [created]
types: [ created ]
schedule:
-
cron: "0 1 * * 6" # Run at 1am every Saturday
Expand All @@ -21,11 +21,11 @@ jobs:
strategy:
fail-fast: false
matrix:
php: ["8.1", "8.2"]
symfony: ["^6.4"]
sylius: ["^1.12"]
node: ["18.x"]
mysql: ["5.7", "8.0"]
php: [ "8.1", "8.2" ]
symfony: [ "^6.4" ]
sylius: [ "^1.12" ]
node: [ "18.x" ]
mysql: [ "5.7", "8.0" ]

env:
APP_ENV: test
Expand Down Expand Up @@ -142,6 +142,7 @@ jobs:
name: Prepare test application assets
run: |
(cd tests/Application && bin/console assets:install public -vvv)
(cd tests/Application && bin/console sylius:install:assets -vvv)
(cd tests/Application && yarn build:prod)
-
Expand All @@ -156,6 +157,18 @@ jobs:
name: Validate database schema
run: (cd tests/Application && bin/console doctrine:schema:validate)

-
name: Install certificates
run: symfony server:ca:install

-
name: Run webserver
run: (cd tests/Application && symfony server:start --port=8080 --dir=public --daemon)

-
name: Run Chrome Headless
run: google-chrome-stable --enable-automation --disable-background-networking --no-default-browser-check --no-first-run --disable-popup-blocking --disable-default-apps --disable-translate --disable-extensions --no-sandbox --enable-features=Metal --headless --remote-debugging-port=9222 --window-size=2880,1800 --proxy-server='direct://' --proxy-bypass-list='*' https://127.0.0.1 > /dev/null 2>&1 &

-
name: Run tests
run: composer tests
Expand Down

0 comments on commit 359a23d

Please sign in to comment.