Skip to content

Commit 4fa2750

Browse files
committed
ci: log package versions + fix for logger [ci clean]
1 parent e8cd2ac commit 4fa2750

18 files changed

Lines changed: 113 additions & 71 deletions

File tree

e2e/__cases__/hoisting/hello.spec.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import hello from './hello';
22

33
afterAll(() => {
44
// this should go after
5+
const zz = 20;
56
jest.unmock('./hello');
67
})
78

e2e/__helpers__/test-case/runtime.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import {
2020
outputJsonSync,
2121
} from 'fs-extra'
2222
import merge from 'lodash.merge'
23-
import { sync as spawnSync } from 'cross-spawn'
23+
import { spawnSync } from 'child_process'
2424

2525
const TEMPLATE_EXCLUDED_ITEMS = ['node_modules', 'package-lock.json']
2626

@@ -96,6 +96,11 @@ export function run(name: string, options: RunTestOptions = {}): RunResult {
9696
)))
9797
}
9898

99+
// run in band
100+
if (!cmdArgs.includes('--runInBand')) {
101+
cmdArgs.push('--runInBand')
102+
}
103+
99104
const cmd = cmdArgs.shift() as string
100105

101106
// Add both process.env which is the standard and custom env variables

e2e/__templates__/with-babel-6/package-lock.json

Lines changed: 0 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

e2e/__templates__/with-babel-6/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
"devDependencies": {
66
"@types/jest": "^23.3.1",
77
"babel-core": "^6.26.3",
8-
"closest-file-data": "^0.1.4",
98
"jest": "^23.4.2",
109
"typescript": "^3.0.1"
1110
}

e2e/__templates__/with-babel-7/package-lock.json

Lines changed: 0 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

e2e/__templates__/with-babel-7/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
"@babel/core": "^7.0.0-beta.56",
77
"@types/jest": "^23.3.1",
88
"babel-core": "^7.0.0-bridge.0",
9-
"closest-file-data": "^0.1.4",
109
"jest": "^23.4.2",
1110
"typescript": "^3.0.1"
1211
}

e2e/__tests__/__snapshots__/hoisting.test.ts.snap

Lines changed: 31 additions & 21 deletions
Large diffs are not rendered by default.

e2e/__tests__/__snapshots__/simple.test.ts.snap

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// Jest Snapshot v1, https://goo.gl/fbAQLP
22

33
exports[`Simple test should pass using template "default" 1`] = `
4-
√ jest
4+
√ jest --runInBand
55
↳ exit code: 0
66
===[ STDOUT ]===================================================================
77
@@ -19,7 +19,7 @@ exports[`Simple test should pass using template "default" 1`] = `
1919
`;
2020

2121
exports[`Simple test should pass using template "with-babel-6" 1`] = `
22-
√ jest
22+
√ jest --runInBand
2323
↳ exit code: 0
2424
===[ STDOUT ]===================================================================
2525
@@ -37,7 +37,7 @@ exports[`Simple test should pass using template "with-babel-6" 1`] = `
3737
`;
3838

3939
exports[`Simple test should pass using template "with-babel-7" 1`] = `
40-
√ jest
40+
√ jest --runInBand
4141
↳ exit code: 0
4242
===[ STDOUT ]===================================================================
4343
@@ -55,7 +55,7 @@ exports[`Simple test should pass using template "with-babel-7" 1`] = `
5555
`;
5656

5757
exports[`Simple test should pass using template "with-jest-22" 1`] = `
58-
√ jest
58+
√ jest --runInBand
5959
↳ exit code: 0
6060
===[ STDOUT ]===================================================================
6161
@@ -73,7 +73,7 @@ exports[`Simple test should pass using template "with-jest-22" 1`] = `
7373
`;
7474

7575
exports[`Simple test should pass using template "with-typescript-2-7" 1`] = `
76-
√ jest
76+
√ jest --runInBand
7777
↳ exit code: 0
7878
===[ STDOUT ]===================================================================
7979

e2e/__tests__/__snapshots__/source-map.test.ts.snap

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ exports[`using template "default" should have the source mpas comment 1`] = `
3535
`;
3636
3737
exports[`using template "default" should report correct line numbers 1`] = `
38-
× jest
38+
× jest --runInBand
3939
↳ exit code: 1
4040
===[ STDOUT ]===================================================================
4141
console.log main.ts:2
@@ -123,7 +123,7 @@ exports[`using template "with-babel-6" should have the source mpas comment 1`] =
123123
`;
124124
125125
exports[`using template "with-babel-6" should report correct line numbers 1`] = `
126-
× jest
126+
× jest --runInBand
127127
↳ exit code: 1
128128
===[ STDOUT ]===================================================================
129129
console.log main.ts:2
@@ -217,7 +217,7 @@ exports[`using template "with-babel-7" should have the source mpas comment 1`] =
217217
`;
218218
219219
exports[`using template "with-babel-7" should report correct line numbers 1`] = `
220-
× jest
220+
× jest --runInBand
221221
↳ exit code: 1
222222
===[ STDOUT ]===================================================================
223223
console.log main.ts:2
@@ -305,7 +305,7 @@ exports[`using template "with-jest-22" should have the source mpas comment 1`] =
305305
`;
306306
307307
exports[`using template "with-jest-22" should report correct line numbers 1`] = `
308-
× jest
308+
× jest --runInBand
309309
↳ exit code: 1
310310
===[ STDOUT ]===================================================================
311311
console.log main.ts:2
@@ -391,7 +391,7 @@ exports[`using template "with-typescript-2-7" should have the source mpas commen
391391
`;
392392
393393
exports[`using template "with-typescript-2-7" should report correct line numbers 1`] = `
394-
× jest
394+
× jest --runInBand
395395
↳ exit code: 1
396396
===[ STDOUT ]===================================================================
397397
console.log main.ts:2

e2e/__tests__/__snapshots__/type-checking.test.ts.snap

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// Jest Snapshot v1, https://goo.gl/fbAQLP
22

33
exports[`With type checking should fail using template "default" 1`] = `
4-
× jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"typeCheck":true}}}
4+
× jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"typeCheck":true}}} --runInBand
55
↳ exit code: 1
66
===[ STDOUT ]===================================================================
77
@@ -24,7 +24,7 @@ exports[`With type checking should fail using template "default" 1`] = `
2424
`;
2525

2626
exports[`With type checking should fail using template "with-babel-6" 1`] = `
27-
× jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"babelConfig":true,"typeCheck":true}}}
27+
× jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"babelConfig":true,"typeCheck":true}}} --runInBand
2828
↳ exit code: 1
2929
===[ STDOUT ]===================================================================
3030
@@ -47,7 +47,7 @@ exports[`With type checking should fail using template "with-babel-6" 1`] = `
4747
`;
4848

4949
exports[`With type checking should fail using template "with-babel-7" 1`] = `
50-
× jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"babelConfig":true,"typeCheck":true}}}
50+
× jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"babelConfig":true,"typeCheck":true}}} --runInBand
5151
↳ exit code: 1
5252
===[ STDOUT ]===================================================================
5353
@@ -70,7 +70,7 @@ exports[`With type checking should fail using template "with-babel-7" 1`] = `
7070
`;
7171

7272
exports[`With type checking should fail using template "with-jest-22" 1`] = `
73-
× jest --config {"transform":{"^.+\\\\.tsx?$":"ts-jest"},"testMatch":["**/__tests__/**/*.js?(x)","**/?(*.)+(spec|test).js?(x)","**/__tests__/**/*.ts?(x)","**/?(*.)+(spec|test).ts?(x)"],"moduleFileExtensions":["js","json","jsx","node","ts","tsx"],"testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"typeCheck":true}}}
73+
× jest --config {"transform":{"^.+\\\\.tsx?$":"ts-jest"},"testMatch":["**/__tests__/**/*.js?(x)","**/?(*.)+(spec|test).js?(x)","**/__tests__/**/*.ts?(x)","**/?(*.)+(spec|test).ts?(x)"],"moduleFileExtensions":["js","json","jsx","node","ts","tsx"],"testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"typeCheck":true}}} --runInBand
7474
↳ exit code: 1
7575
===[ STDOUT ]===================================================================
7676
@@ -93,7 +93,7 @@ exports[`With type checking should fail using template "with-jest-22" 1`] = `
9393
`;
9494

9595
exports[`With type checking should fail using template "with-typescript-2-7" 1`] = `
96-
× jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"diagnostics":{"ignoreCodes":[5023]},"typeCheck":true}}}
96+
× jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"diagnostics":{"ignoreCodes":[5023]},"typeCheck":true}}} --runInBand
9797
↳ exit code: 1
9898
===[ STDOUT ]===================================================================
9999
@@ -116,7 +116,7 @@ exports[`With type checking should fail using template "with-typescript-2-7" 1`]
116116
`;
117117

118118
exports[`Without type checking should pass using template "default" 1`] = `
119-
√ jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"typeCheck":false}}}
119+
√ jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"typeCheck":false}}} --runInBand
120120
↳ exit code: 0
121121
===[ STDOUT ]===================================================================
122122
@@ -133,7 +133,7 @@ exports[`Without type checking should pass using template "default" 1`] = `
133133
`;
134134

135135
exports[`Without type checking should pass using template "with-babel-6" 1`] = `
136-
√ jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"babelConfig":true,"typeCheck":false}}}
136+
√ jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"babelConfig":true,"typeCheck":false}}} --runInBand
137137
↳ exit code: 0
138138
===[ STDOUT ]===================================================================
139139
@@ -150,7 +150,7 @@ exports[`Without type checking should pass using template "with-babel-6" 1`] = `
150150
`;
151151

152152
exports[`Without type checking should pass using template "with-babel-7" 1`] = `
153-
√ jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"babelConfig":true,"typeCheck":false}}}
153+
√ jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"babelConfig":true,"typeCheck":false}}} --runInBand
154154
↳ exit code: 0
155155
===[ STDOUT ]===================================================================
156156
@@ -167,7 +167,7 @@ exports[`Without type checking should pass using template "with-babel-7" 1`] = `
167167
`;
168168

169169
exports[`Without type checking should pass using template "with-jest-22" 1`] = `
170-
√ jest --config {"transform":{"^.+\\\\.tsx?$":"ts-jest"},"testMatch":["**/__tests__/**/*.js?(x)","**/?(*.)+(spec|test).js?(x)","**/__tests__/**/*.ts?(x)","**/?(*.)+(spec|test).ts?(x)"],"moduleFileExtensions":["js","json","jsx","node","ts","tsx"],"testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"typeCheck":false}}}
170+
√ jest --config {"transform":{"^.+\\\\.tsx?$":"ts-jest"},"testMatch":["**/__tests__/**/*.js?(x)","**/?(*.)+(spec|test).js?(x)","**/__tests__/**/*.ts?(x)","**/?(*.)+(spec|test).ts?(x)"],"moduleFileExtensions":["js","json","jsx","node","ts","tsx"],"testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"typeCheck":false}}} --runInBand
171171
↳ exit code: 0
172172
===[ STDOUT ]===================================================================
173173
@@ -184,7 +184,7 @@ exports[`Without type checking should pass using template "with-jest-22" 1`] = `
184184
`;
185185

186186
exports[`Without type checking should pass using template "with-typescript-2-7" 1`] = `
187-
√ jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"diagnostics":{"ignoreCodes":[5023]},"typeCheck":false}}}
187+
√ jest --config {"preset":"ts-jest","testEnvironment":"node","globals":{"ts-jest":{"tsConfig":{},"diagnostics":{"ignoreCodes":[5023]},"typeCheck":false}}} --runInBand
188188
↳ exit code: 0
189189
===[ STDOUT ]===================================================================
190190

0 commit comments

Comments
 (0)