Skip to content

Commit 9fa9829

Browse files
Move E2E into tools folder
1 parent 775ce25 commit 9fa9829

File tree

5 files changed

+25
-93
lines changed

5 files changed

+25
-93
lines changed

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,9 @@
5353
"tsc": "tsc",
5454
"format-php": "composer format:all",
5555
"phpstan": "composer phpstan",
56-
"test-e2e": "wp-scripts test-playwright --config plugins/auto-sizes/tests/e2e/playwright.config.ts",
57-
"test-e2e:debug": "wp-scripts test-playwright --config plugins/auto-sizes/tests/e2e/playwright.config.ts --ui",
56+
"test-e2e": "wp-scripts test-playwright --config tools/e2e/playwright.config.ts",
57+
"test-e2e:debug": "wp-scripts test-playwright --config tools/e2e/playwright.config.ts --ui",
58+
"test-e2e:auto-sizes": "wp-scripts test-playwright --config tools/e2e/playwright.config.ts --project=auto-sizes",
5859
"lint-php": "composer lint:all",
5960
"test-php": "wp-env run tests-cli --env-cwd=/var/www/html/wp-content/plugins/performance composer test:plugins",
6061
"test-php-watch": "./bin/test-php-watch.sh",

plugins/auto-sizes/tests/e2e/config/global-setup.ts

Lines changed: 0 additions & 39 deletions
This file was deleted.

plugins/auto-sizes/tests/e2e/playwright.config.ts

Lines changed: 0 additions & 51 deletions
This file was deleted.

tools/e2e/playwright.config.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/**
2+
* External dependencies
3+
*/
4+
import { defineConfig } from '@playwright/test';
5+
6+
/**
7+
* WordPress dependencies
8+
*/
9+
import baseConfig from '@wordpress/scripts/config/playwright.config.js';
10+
11+
const config = defineConfig( {
12+
...baseConfig,
13+
projects: [
14+
{
15+
name: 'auto-sizes',
16+
testDir: '../../plugins/auto-sizes/tests/e2e/specs',
17+
},
18+
],
19+
} );
20+
21+
export default config;

tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
},
1111
"include": [
1212
"plugins/**/*.js",
13-
"plugins/**/*.ts",
13+
"plugins/**/*.ts", "tools/**/*.ts",
1414
],
1515
"exclude": [
1616
"plugins/*/build/*"

0 commit comments

Comments
 (0)