Commit ee40939 1 parent e715a27 commit ee40939 Copy full SHA for ee40939
File tree 3 files changed +6
-6
lines changed
3 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -38,7 +38,7 @@ Launches end to end tests.
38
38
39
39
It requires:
40
40
41
- - Install playwright dependencies ` cd ./front/ && yarn playwright install --with-deps `
41
+ - Install playwright dependencies ` cd ./front/ && npx playwright install --with-deps `
42
42
- Backend containers to be up:
43
43
` docker compose up --no-build --detach valkey postgres gateway core editoast `
44
44
- Running front with ` docker compose up --build --detach front `
@@ -48,7 +48,7 @@ Now you can run the test with `cd front/ && npm run e2e-tests`.
48
48
If you are using a Linux distribution not supported by playwright (which only supports Windows,
49
49
macOS and Ubuntu/Debian), you can instead start the tests inside a docker container using
50
50
` osrd/scripts/run-front-playwright-container.sh ` . You may pass the same options and arguments to
51
- this script as you would to ` yarn e2e-tests` or ` yarn playwright test` .
51
+ this script as you would to ` npm run e2e-tests` or ` npx playwright test` .
52
52
53
53
> [ !CAUTION] If you try to run ` npm run start ` instead of running it through docker, you'll notice
54
54
> it doesn't work because the gateway can't access your local port from inside a container. 2
Original file line number Diff line number Diff line change 1
1
ARG PLAYWRIGHT_VERSION=latest
2
2
FROM mcr.microsoft.com/playwright:$PLAYWRIGHT_VERSION
3
3
4
- COPY front/package.json front/yarn. lock /app/front/
4
+ COPY front/package.json front/package- lock.json /app/front/
5
5
WORKDIR /app/front
6
- RUN yarn install --frozen-lockfile
6
+ RUN npm install --frozen-lockfile
7
7
8
8
COPY front /app/front/
9
9
COPY tests /app/tests
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ if ! command -v jq &> /dev/null; then
11
11
exit 1
12
12
fi
13
13
cd front
14
- VERSION=$( yarn list --pattern playwright --json | jq -r ' .data.trees[].name | split("@")[-1] ' | sort -u)
14
+ VERSION=$( npm list --pattern playwright --json | jq -r ' .dependencies["@playwright/test"].version ' | sort -u)
15
15
if [ " $( echo " $VERSION " | wc -l) " -ne 1 ]; then
16
16
echo " Error: Zero or multiple playwright versions found: $VERSION " >&2
17
17
exit 1
@@ -40,4 +40,4 @@ docker run -it --rm \
40
40
-v " $PWD /front/playwright-report:/app/front/playwright-report" \
41
41
-v " $PWD /front/test-results:/app/front/test-results" \
42
42
-u " $( stat -c %u:%g .) " \
43
- osrd-playwright:latest yarn playwright test " ${args[@]} "
43
+ osrd-playwright:latest npx playwright test " ${args[@]} "
You can’t perform that action at this time.
0 commit comments