2938aba484
* base front production image on official nginx * build multi-platform docker images * build message types outside docker * set docker build context to path * build message types before running e2e tests * add build for arm/v7 * remove build for arm/v7 * increase yarn network timeout * set front port to 80 * add git labels to images https://github.com/docker/build-push-action/blob/master/UPGRADE.md#tags-with-ref-and-git-labels * add images input * Adding back commented code in the Dockerfile (the protobuf message building). This way, when node-grpc supports ARM64, we can uncomment the code again. Co-authored-by: David Négrier <d.negrier@thecodingmachine.com> Co-authored-by: Lukas Hass @lukashass
56 lines
828 B
Markdown
56 lines
828 B
Markdown
# End-to-end tests
|
|
|
|
This directory contains automated end to end tests.
|
|
|
|
## Installation
|
|
|
|
```bash
|
|
npm install
|
|
npx playwright install --with-deps
|
|
```
|
|
|
|
## Run on development environment
|
|
|
|
Start WorkAdventure with:
|
|
|
|
```bash
|
|
docker-compose up -d
|
|
```
|
|
|
|
Wait 2-3 minutes for the environment to start, then:
|
|
|
|
Start the tests with:
|
|
|
|
```bash
|
|
npm run test
|
|
```
|
|
|
|
## Run on production like environment
|
|
|
|
Build message types:
|
|
|
|
```bash
|
|
cd messages/
|
|
yarn run proto-all
|
|
```
|
|
|
|
Start WorkAdventure with:
|
|
|
|
```bash
|
|
docker-compose -f docker-compose.yaml -f docker-compose.e2e.yml up -d --build
|
|
```
|
|
|
|
Start the tests with:
|
|
|
|
```bash
|
|
npm run test-prod-like
|
|
```
|
|
|
|
## Run selected tests
|
|
|
|
End-to-end tests can take a while to run. To run only one test in one browser, use:
|
|
|
|
```bash
|
|
npm run test -- [name of the test file] --project=[chromium|firefox|webkit]
|
|
```
|