Skip to content

Commit 38b1014

Browse files
authored
Merge branch 'main' into feat/i18n-de
2 parents 5511c19 + 569dff0 commit 38b1014

File tree

3 files changed

+18
-4
lines changed

3 files changed

+18
-4
lines changed

CONTRIBUTING.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -752,6 +752,23 @@ pnpm test:browser:ui # Run with Playwright UI
752752

753753
Make sure to read about [Playwright best practices](https://playwright.dev/docs/best-practices) and don't rely on classes/IDs but try to follow user-replicable behaviour (like selecting an element based on text content instead).
754754

755+
#### Updating snapshots
756+
757+
Some tests use image snapshots that must match the CI environment (Linux). If you need to update them, and aren't running Linux, you can use Docker to run in the same environment:
758+
759+
```bash
760+
docker run --rm \
761+
-e CI=true \
762+
-e NODE_OPTIONS="--max-old-space-size=4096" \
763+
-v $(pwd):/work \
764+
-w /work \
765+
mcr.microsoft.com/playwright:v1.58.2-noble \
766+
sh -c "npm install -g pnpm && pnpm install && pnpm vp run build:test && pnpm vp run test:browser:prebuilt --update-snapshots"
767+
```
768+
769+
> [!NOTE]
770+
> If the build runs out of memory, increase `--max-old-space-size` to `8192`.
771+
755772
### Test fixtures (mocking external APIs)
756773

757774
E2E tests use a fixture system to mock external API requests, ensuring tests are deterministic and don't hit real APIs. This is handled at two levels:

playwright.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export default defineConfig<ConfigOptions>({
1515
webServer: {
1616
command: 'pnpm start:playwright:webserver',
1717
url: baseURL,
18-
reuseExistingServer: false,
18+
reuseExistingServer: !process.env.CI,
1919
timeout: 60_000,
2020
},
2121
// Start/stop mock connector server before/after all tests (teardown via returned closure)

scripts/compare-translations.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -407,9 +407,6 @@ const run = async (): Promise<void> => {
407407
lang: 'en',
408408
})
409409

410-
// TODO: removing vacations entry key for temporal recharging page
411-
delete referenceContent.vacations
412-
413410
// $schema is a JSON Schema reference, not a translation key
414411
delete referenceContent.$schema
415412

0 commit comments

Comments
 (0)