Skip to content

Commit f161240

Browse files
authored
chore: speed up e2e tests by adding a few caching layers
1 parent d3ebfe8 commit f161240

File tree

72 files changed

+215964
-93
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

72 files changed

+215964
-93
lines changed

.github/workflows/main.yml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,18 @@ jobs:
1111
with:
1212
node-version: 12
1313

14-
- name: Get yarn cache
14+
- name: Yarn cache directory
1515
id: yarn-cache
1616
run: echo "::set-output name=dir::$(yarn cache dir)"
1717

18-
- uses: actions/cache@v1
18+
- name: Yarn cache
19+
uses: actions/cache@v2
1920
with:
2021
path: ${{ steps.yarn-cache.outputs.dir }}
2122
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
2223
restore-keys: |
2324
${{ runner.os }}-yarn-
24-
25+
2526
- name: Install dependencies
2627
run: yarn install --frozen-lockfile
2728

@@ -49,16 +50,17 @@ jobs:
4950
with:
5051
node-version: ${{ matrix.node }}
5152

52-
- name: Get yarn cache
53+
- name: Yarn cache directory
5354
id: yarn-cache
5455
run: echo "::set-output name=dir::$(yarn cache dir)"
5556

56-
- uses: actions/cache@v1
57+
- name: Yarn cache
58+
uses: actions/cache@v2
5759
with:
5860
path: ${{ steps.yarn-cache.outputs.dir }}
59-
key: ${{ runner.os }}-node-${{ matrix.node }}-yarn-${{ hashFiles('**/yarn.lock') }}
61+
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
6062
restore-keys: |
61-
${{ runner.os }}-node-${{ matrix.node }}-yarn-
63+
${{ runner.os }}-yarn-
6264
6365
- name: Install dependencies
6466
run: yarn install --frozen-lockfile

test/e2e/EsLint.spec.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
import { join } from 'path';
22
import { readFixture } from './sandbox/Fixture';
3-
import { Sandbox, createSandbox, FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION } from './sandbox/Sandbox';
3+
import { Sandbox, createSandbox } from './sandbox/Sandbox';
44
import {
55
createWebpackDevServerDriver,
66
WEBPACK_CLI_VERSION,
77
WEBPACK_DEV_SERVER_VERSION,
88
} from './sandbox/WebpackDevServerDriver';
9+
import { FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION } from './sandbox/Plugin';
910

1011
describe('EsLint', () => {
1112
let sandbox: Sandbox;

test/e2e/OutOfMemoryAndCosmiconfig.spec.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
import { join } from 'path';
2-
import { createSandbox, FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION, Sandbox } from './sandbox/Sandbox';
2+
import { createSandbox, Sandbox } from './sandbox/Sandbox';
33
import { readFixture } from './sandbox/Fixture';
44
import { createGenericProcessDriver } from './sandbox/GenericProcessDriver';
5+
import { FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION } from './sandbox/Plugin';
56

67
describe('ForkTsCheckerWebpackPlugin Out Of Memory and Cosmiconfig', () => {
78
let sandbox: Sandbox;

test/e2e/TypeDefinitions.spec.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
import { createSandbox, FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION, Sandbox } from './sandbox/Sandbox';
2-
import { readFixture } from './sandbox/Fixture';
31
import { join } from 'path';
2+
import { createSandbox, Sandbox } from './sandbox/Sandbox';
3+
import { readFixture } from './sandbox/Fixture';
4+
import { FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION } from './sandbox/Plugin';
45

56
describe('Type Definitions', () => {
67
let sandbox: Sandbox;

test/e2e/TypeScriptConfigurationChange.spec.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
1-
import { createSandbox, FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION, Sandbox } from './sandbox/Sandbox';
2-
import { readFixture } from './sandbox/Fixture';
31
import { join } from 'path';
2+
import { createSandbox, Sandbox } from './sandbox/Sandbox';
3+
import { readFixture } from './sandbox/Fixture';
44
import {
55
createWebpackDevServerDriver,
66
WEBPACK_CLI_VERSION,
77
WEBPACK_DEV_SERVER_VERSION,
88
} from './sandbox/WebpackDevServerDriver';
9+
import { FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION } from './sandbox/Plugin';
910

1011
describe('TypeScript Configuration Change', () => {
1112
let sandbox: Sandbox;

test/e2e/TypeScriptConfigurationOverwrite.spec.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
1-
import { createSandbox, FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION, Sandbox } from './sandbox/Sandbox';
2-
import { readFixture } from './sandbox/Fixture';
31
import { join } from 'path';
2+
import { createSandbox, Sandbox } from './sandbox/Sandbox';
3+
import { readFixture } from './sandbox/Fixture';
44
import {
55
createWebpackDevServerDriver,
66
WEBPACK_CLI_VERSION,
77
WEBPACK_DEV_SERVER_VERSION,
88
WebpackDevServerDriver,
99
} from './sandbox/WebpackDevServerDriver';
10+
import { FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION } from './sandbox/Plugin';
1011

1112
describe('TypeScript Compiler Options parsing', () => {
1213
let sandbox: Sandbox;

test/e2e/TypeScriptContextOption.spec.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
import { readFixture } from './sandbox/Fixture';
22
import { join } from 'path';
3-
import { createSandbox, FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION, Sandbox } from './sandbox/Sandbox';
3+
import { createSandbox, Sandbox } from './sandbox/Sandbox';
44
import {
55
createWebpackDevServerDriver,
66
WEBPACK_CLI_VERSION,
77
WEBPACK_DEV_SERVER_VERSION,
88
} from './sandbox/WebpackDevServerDriver';
9+
import { FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION } from './sandbox/Plugin';
910

1011
describe('TypeScript Context Option', () => {
1112
let sandbox: Sandbox;

test/e2e/TypeScriptPnpSupport.spec.ts

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,12 @@
1-
import {
2-
createSandbox,
3-
FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION,
4-
Sandbox,
5-
yarnInstaller,
6-
} from './sandbox/Sandbox';
7-
import { readFixture } from './sandbox/Fixture';
81
import { join } from 'path';
2+
import { createSandbox, Sandbox, yarnInstaller } from './sandbox/Sandbox';
3+
import { readFixture } from './sandbox/Fixture';
94
import {
105
createWebpackDevServerDriver,
116
WEBPACK_CLI_VERSION,
127
WEBPACK_DEV_SERVER_VERSION,
138
} from './sandbox/WebpackDevServerDriver';
9+
import { FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION } from './sandbox/Plugin';
1410

1511
describe('TypeScript PnP Support', () => {
1612
let sandbox: Sandbox;

test/e2e/TypeScriptSolutionBuilderApi.spec.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
import { join } from 'path';
22
import { readFixture } from './sandbox/Fixture';
3-
import { Sandbox, createSandbox, FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION } from './sandbox/Sandbox';
3+
import { Sandbox, createSandbox } from './sandbox/Sandbox';
44
import {
55
createWebpackDevServerDriver,
66
WEBPACK_CLI_VERSION,
77
WEBPACK_DEV_SERVER_VERSION,
88
} from './sandbox/WebpackDevServerDriver';
9+
import { FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION } from './sandbox/Plugin';
910

1011
describe('TypeScript SolutionBuilder API', () => {
1112
let sandbox: Sandbox;

test/e2e/TypeScriptVueExtension.spec.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
1-
import { createSandbox, FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION, Sandbox } from './sandbox/Sandbox';
2-
import { readFixture } from './sandbox/Fixture';
31
import { join } from 'path';
2+
import { createSandbox, Sandbox } from './sandbox/Sandbox';
3+
import { readFixture } from './sandbox/Fixture';
44
import {
55
createWebpackDevServerDriver,
66
WEBPACK_CLI_VERSION,
77
WEBPACK_DEV_SERVER_VERSION,
88
} from './sandbox/WebpackDevServerDriver';
9+
import { FORK_TS_CHECKER_WEBPACK_PLUGIN_VERSION } from './sandbox/Plugin';
910

1011
describe('TypeScript Vue Extension', () => {
1112
let sandbox: Sandbox;

0 commit comments

Comments
 (0)