@dargmuesli/nuxt-vio-testing 20.5.2 → 20.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,6 +2,7 @@ import { expect } from '@playwright/test'
2
2
  import type { Page } from 'playwright-core'
3
3
 
4
4
  export const COOKIE_CONTROL_CONSENT_COOKIE_DEFAULT = 'ctga'
5
+ export const TIMEOUT = 60000
5
6
  export const PAGE_READY = async ({
6
7
  page,
7
8
  options,
package/package.json CHANGED
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "devDependencies": {
3
- "@axe-core/playwright": "4.11.0",
3
+ "@axe-core/playwright": "4.11.1",
4
4
  "@eslint/js": "9.39.2",
5
5
  "@playwright/test": "1.58.1",
6
- "@types/node": "24.10.9",
6
+ "@types/node": "24.10.10",
7
7
  "cross-env": "10.1.0",
8
8
  "eslint": "9.39.2",
9
9
  "eslint-config-prettier": "10.1.8",
@@ -49,10 +49,10 @@
49
49
  "test:e2e:docker:server:node:update": "pnpm run test:e2e:docker:server:node --update-snapshots",
50
50
  "test:e2e:docker:server:static": "pnpm run test:e2e:docker:br pnpm run --dir tests test:e2e:server:static",
51
51
  "test:e2e:docker:server:static:update": "pnpm run test:e2e:docker:server:static --update-snapshots",
52
- "test:e2e:server:dev": "cross-env PORT=3000 NUXT_PUBLIC_SITE_URL=http://localhost:3000 VIO_SERVER=dev pnpm run test:e2e",
53
- "test:e2e:server:node": "cross-env NODE_ENV=production NUXT_PUBLIC_I18N_BASE_URL=http://localhost:3001 NUXT_PUBLIC_SITE_URL=http://localhost:3001 PORT=3001 VIO_SERVER=node pnpm run test:e2e",
52
+ "test:e2e:server:dev": "cross-env PORT=3000 NUXT_PUBLIC_SITE_URL=https://localhost:3000 VIO_SERVER=dev pnpm run test:e2e",
53
+ "test:e2e:server:node": "cross-env NODE_ENV=production NODE_EXTRA_CA_CERTS=\"$(mkcert -CAROOT)/rootCA.pem\" NUXT_PUBLIC_I18N_BASE_URL=https://localhost:3001 NUXT_PUBLIC_SITE_URL=https://localhost:3001 PORT=3001 VIO_SERVER=node pnpm run test:e2e",
54
54
  "test:e2e:server:static": "cross-env NODE_ENV=production PORT=3002 NUXT_PUBLIC_SITE_URL=https://localhost:3002 VIO_SERVER=static pnpm run test:e2e"
55
55
  },
56
56
  "type": "module",
57
- "version": "20.5.2"
57
+ "version": "20.6.0"
58
58
  }
@@ -1,6 +1,7 @@
1
1
  import { defineConfig, devices } from '@playwright/test'
2
2
 
3
- import { SITE_URL } from './e2e/utils/constants'
3
+ import { SITE_URL } from '#src/node/static'
4
+ import { TIMEOUT } from '#tests/e2e/utils/constants'
4
5
 
5
6
  /**
6
7
  * Read environment variables from file.
@@ -86,13 +87,13 @@ export default defineConfig({
86
87
 
87
88
  /* Run your local dev server before starting the tests */
88
89
  webServer: {
89
- command: `pnpm run --dir ../src start:${process.env.VIO_SERVER || 'dev'}`,
90
+ command: `pnpm --dir ../src run certificates && pnpm --dir ../src run start:${process.env.VIO_SERVER || 'dev'}`,
90
91
  env: {
91
92
  NUXT_PUBLIC_VIO_IS_TESTING: 'true',
92
93
  },
93
94
  ignoreHTTPSErrors: true, // TODO: remove once tests run without it
94
- timeout: process.env.NODE_ENV === 'production' ? 10000 : 100000,
95
- url: process.env.SITE_URL || SITE_URL,
95
+ timeout: TIMEOUT,
96
+ url: SITE_URL,
96
97
  reuseExistingServer: !process.env.CI,
97
98
  },
98
99
 
package/tsconfig.json CHANGED
@@ -3,6 +3,8 @@
3
3
  "module": "ESNext",
4
4
  "moduleResolution": "Bundler",
5
5
  "paths": {
6
+ "~/*": ["../src/*"],
7
+ "#src/*": ["../src/*"],
6
8
  "#tests/*": ["./*"]
7
9
  },
8
10
  "target": "ESNext",