try to add e2e job
This commit is contained in:
1
Makefile
1
Makefile
@@ -109,6 +109,7 @@ js-build: ; $(NPM) $(NPM_FLAGS) run build-prod
|
|||||||
js-deps: ; $(NPM) $(NPM_INSTALL_FLAGS) ci
|
js-deps: ; $(NPM) $(NPM_INSTALL_FLAGS) ci
|
||||||
js-lint: ; $(NPM) $(NPM_FLAGS) run lint
|
js-lint: ; $(NPM) $(NPM_FLAGS) run lint
|
||||||
js-test: ; $(NPM) $(NPM_FLAGS) run test
|
js-test: ; $(NPM) $(NPM_FLAGS) run test
|
||||||
|
js-test-e2e: ; $(NPM) $(NPM_FLAGS) run test:e2e
|
||||||
|
|
||||||
go-bench: ; $(ENV) "$(SHELL)" ./scripts/make/go-bench.sh
|
go-bench: ; $(ENV) "$(SHELL)" ./scripts/make/go-bench.sh
|
||||||
go-build: ; $(ENV) "$(SHELL)" ./scripts/make/go-build.sh
|
go-build: ; $(ENV) "$(SHELL)" ./scripts/make/go-build.sh
|
||||||
|
|||||||
@@ -28,6 +28,7 @@
|
|||||||
final: false
|
final: false
|
||||||
jobs:
|
jobs:
|
||||||
- 'Artifact'
|
- 'Artifact'
|
||||||
|
- 'Test e2e'
|
||||||
|
|
||||||
'Test frontend':
|
'Test frontend':
|
||||||
'docker':
|
'docker':
|
||||||
@@ -165,6 +166,29 @@
|
|||||||
'requirements':
|
'requirements':
|
||||||
- 'adg-docker': 'true'
|
- 'adg-docker': 'true'
|
||||||
|
|
||||||
|
'Test e2e':
|
||||||
|
'docker':
|
||||||
|
'image': '${bamboo.dockerFrontend}'
|
||||||
|
'volumes':
|
||||||
|
'${system.YARN_DIR}': '${bamboo.cacheYarn}'
|
||||||
|
'key': 'E2ETEST'
|
||||||
|
'other':
|
||||||
|
'clean-working-dir': true
|
||||||
|
'tasks':
|
||||||
|
- 'checkout':
|
||||||
|
'force-clean-build': true
|
||||||
|
- 'script':
|
||||||
|
'interpreter': 'SHELL'
|
||||||
|
'scripts':
|
||||||
|
- |
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
set -e -f -u -x
|
||||||
|
|
||||||
|
make VERBOSE=1 js-test-e2e
|
||||||
|
'requirements':
|
||||||
|
- 'adg-docker': 'true'
|
||||||
|
|
||||||
'branches':
|
'branches':
|
||||||
'create': 'for-pull-request'
|
'create': 'for-pull-request'
|
||||||
'delete':
|
'delete':
|
||||||
|
|||||||
2
client/package.json
vendored
2
client/package.json
vendored
@@ -10,7 +10,7 @@
|
|||||||
"lint": "echo 'Lint temporarily disabled'",
|
"lint": "echo 'Lint temporarily disabled'",
|
||||||
"lint-new": "eslint './src/**/*.(ts|tsx)'",
|
"lint-new": "eslint './src/**/*.(ts|tsx)'",
|
||||||
"lint:fix": "eslint './src/**/*.(ts|tsx)' --fix",
|
"lint:fix": "eslint './src/**/*.(ts|tsx)' --fix",
|
||||||
"test": "vitest --run && npx playwright test",
|
"test": "vitest --run",
|
||||||
"test:watch": "vitest --watch",
|
"test:watch": "vitest --watch",
|
||||||
"test:e2e": "npx playwright test tests/e2e",
|
"test:e2e": "npx playwright test tests/e2e",
|
||||||
"test:e2e:interactive": "npx playwright test --ui",
|
"test:e2e:interactive": "npx playwright test --ui",
|
||||||
|
|||||||
4
client/playwright.config.ts
vendored
4
client/playwright.config.ts
vendored
@@ -69,7 +69,9 @@ export default defineConfig({
|
|||||||
],
|
],
|
||||||
|
|
||||||
webServer: {
|
webServer: {
|
||||||
command: 'rm -f AdGuardHome.yaml && sudo ./AdGuardHome --local-frontend -v',
|
command: process.env.CI
|
||||||
|
? 'rm -f AdGuardHome.yaml && ./AdGuardHome --local-frontend -v'
|
||||||
|
: 'rm -f AdGuardHome.yaml && sudo ./AdGuardHome --local-frontend -v',
|
||||||
url: 'http://127.0.0.1:3000',
|
url: 'http://127.0.0.1:3000',
|
||||||
cwd: '..',
|
cwd: '..',
|
||||||
reuseExistingServer: !process.env.CI,
|
reuseExistingServer: !process.env.CI,
|
||||||
|
|||||||
Reference in New Issue
Block a user