Skip to content

Commit a19d9c4

Browse files
committed
Deleted/moved v1 e2e tests
1 parent 1a769b6 commit a19d9c4

17 files changed

+26
-1799
lines changed

.github/workflows/end_to_end_tests.yaml

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -65,15 +65,9 @@ jobs:
6565
if: matrix.node-version == '18'
6666
run: echo "FRACTAL_SERVER_HOST=http://127.0.0.1:8000" >> $GITHUB_ENV
6767

68-
- name: Run Playwright tests [v1]
68+
- name: Run Playwright tests
6969
run: npx playwright test
7070
env:
71-
TEST_VERSION: v1
72-
73-
- name: Run Playwright tests [v2]
74-
run: npx playwright test
75-
env:
76-
TEST_VERSION: v2
7771
FRACTAL_RUNNER_BACKEND: local_experimental
7872

7973
- name: Archive test results

docs/development/tests.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,6 @@ To print Svelte webserver log set the environment variable `DEBUG=pw:webserver`.
1616

1717
To execute the tests seeing the browser add the `--headed` flag or the `--debug` flag if you need to watch them step by step.
1818

19-
By default v2 tests are run. These tests require running a fractal-server instance using `FRACTAL_RUNNER_BACKEND=local_experimental`.
20-
21-
To run v1 tests start playwright setting the environment variable `TEST_VERSION` to `v1`. These tests require running a fractal-server instance using `FRACTAL_RUNNER_BACKEND=local`.
22-
2319
OAuth2 test requires a running instance of dexidp test image and a fractal-server instance configured to use it.
2420

2521
To skip OAuth2 test set the environment variable `SKIP_OAUTH_TEST` to `true`.

playwright.config.js

Lines changed: 17 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -5,40 +5,27 @@ import dotenv from 'dotenv';
55

66
dotenv.config({ path: '.env.development' });
77

8-
const v1Tests = [
9-
{
10-
name: 'collect_core_tasks',
11-
testMatch: /v1\/collect_core_tasks\.setup\.js/,
12-
use: {
13-
storageState: 'tests/.auth/user.json'
14-
},
15-
dependencies: ['auth']
16-
},
17-
{
18-
name: 'create_fake_task',
19-
testMatch: /v1\/create_fake_task\.setup\.js/,
20-
use: {
21-
storageState: 'tests/.auth/user.json'
22-
},
23-
dependencies: ['collect_core_tasks', 'auth']
24-
},
8+
const commonTests = [
9+
{ name: 'auth', testMatch: /auth\.setup\.js/ },
2510
{
2611
name: 'chromium',
27-
testMatch: /v1\/.*\.spec\.js/,
12+
testMatch: /.*\.spec\.js/,
13+
testIgnore: /v2\/.*\.spec\.js/,
2814
use: {
2915
...devices['Desktop Chrome'],
3016
storageState: 'tests/.auth/user.json'
3117
},
32-
dependencies: ['create_fake_task']
18+
dependencies: ['auth']
3319
},
3420
{
3521
name: 'firefox',
36-
testMatch: /v1\/.*\.spec\.js/,
22+
testMatch: /.*\.spec\.js/,
23+
testIgnore: /v2\/.*\.spec\.js/,
3724
use: {
3825
...devices['Desktop Firefox'],
3926
storageState: 'tests/.auth/user.json'
4027
},
41-
dependencies: ['create_fake_task']
28+
dependencies: ['auth']
4229
}
4330
];
4431

@@ -52,58 +39,38 @@ const v2Tests = [
5239
dependencies: ['auth']
5340
},
5441
{
55-
name: 'chromium',
56-
testMatch: /v2\/.*\.spec\.js/,
42+
name: 'create_fake_task',
43+
testMatch: /v2\/create_fake_task\.setup\.js/,
5744
use: {
58-
...devices['Desktop Chrome'],
5945
storageState: 'tests/.auth/user.json'
6046
},
61-
dependencies: ['collect_mock_tasks']
47+
dependencies: ['auth']
6248
},
63-
{
64-
name: 'firefox',
65-
testMatch: /v2\/.*\.spec\.js/,
66-
use: {
67-
...devices['Desktop Firefox'],
68-
storageState: 'tests/.auth/user.json'
69-
},
70-
dependencies: ['collect_mock_tasks']
71-
}
72-
];
73-
74-
const commonTests = [
75-
{ name: 'auth', testMatch: /auth\.setup\.js/ },
7649
{
7750
name: 'chromium',
78-
testMatch: /.*\.spec\.js/,
79-
testIgnore: /(v1|v2)\/.*\.spec\.js/,
51+
testMatch: /v2\/.*\.spec\.js/,
8052
use: {
8153
...devices['Desktop Chrome'],
8254
storageState: 'tests/.auth/user.json'
8355
},
84-
dependencies: ['auth']
56+
dependencies: ['collect_mock_tasks', 'create_fake_task']
8557
},
8658
{
8759
name: 'firefox',
88-
testMatch: /.*\.spec\.js/,
89-
testIgnore: /(v1|v2)\/.*\.spec\.js/,
60+
testMatch: /v2\/.*\.spec\.js/,
9061
use: {
9162
...devices['Desktop Firefox'],
9263
storageState: 'tests/.auth/user.json'
9364
},
94-
dependencies: ['auth']
65+
dependencies: ['collect_mock_tasks', 'create_fake_task']
9566
}
96-
]
97-
98-
const version = process.env.TEST_VERSION || 'v2';
99-
100-
const tests = version === 'v2' ? v2Tests : v1Tests;
67+
];
10168

10269
export default defineConfig({
10370
testDir: 'tests',
10471
retries: 3,
10572

106-
projects: [...commonTests, ...tests],
73+
projects: [...commonTests, ...v2Tests],
10774

10875
webServer: [
10976
{

tests/v1/add_single_task.spec.js

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

0 commit comments

Comments
 (0)