@@ -19,15 +19,17 @@ function findCoverageFileForPid(pid) {
19
19
} ) ;
20
20
}
21
21
22
- test ( '--test-coverage and --test cannot be combined' , ( ) => {
22
+ test ( '--experimental- test-coverage and --test cannot be combined' , ( ) => {
23
23
// TODO(cjihrig): This test can be removed once multi-process code coverage
24
24
// is supported.
25
- const result = spawnSync ( process . execPath , [ '--test' , '--test-coverage' ] ) ;
25
+ const args = [ '--test' , '--experimental-test-coverage' ] ;
26
+ const result = spawnSync ( process . execPath , args ) ;
26
27
27
28
// 9 is the documented exit code for an invalid CLI argument.
28
29
assert . strictEqual ( result . status , 9 ) ;
29
30
assert . match (
30
- result . stderr . toString ( ) , / - - t e s t - c o v e r a g e c a n n o t b e u s e d w i t h - - t e s t /
31
+ result . stderr . toString ( ) ,
32
+ / - - e x p e r i m e n t a l - t e s t - c o v e r a g e c a n n o t b e u s e d w i t h - - t e s t /
31
33
) ;
32
34
} ) ;
33
35
@@ -37,7 +39,7 @@ test('handles the inspector not being available', (t) => {
37
39
}
38
40
39
41
const fixture = fixtures . path ( 'test-runner' , 'coverage.js' ) ;
40
- const args = [ '--test-coverage' , fixture ] ;
42
+ const args = [ '--experimental- test-coverage' , fixture ] ;
41
43
const result = spawnSync ( process . execPath , args ) ;
42
44
43
45
assert ( ! result . stdout . toString ( ) . includes ( '# start of coverage report' ) ) ;
@@ -52,7 +54,7 @@ test('coverage is reported and dumped to NODE_V8_COVERAGE if present', (t) => {
52
54
}
53
55
54
56
const fixture = fixtures . path ( 'test-runner' , 'coverage.js' ) ;
55
- const args = [ '--test-coverage' , fixture ] ;
57
+ const args = [ '--experimental- test-coverage' , fixture ] ;
56
58
const options = { env : { ...process . env , NODE_V8_COVERAGE : tmpdir . path } } ;
57
59
const result = spawnSync ( process . execPath , args , options ) ;
58
60
const report = [
@@ -78,7 +80,7 @@ test('coverage is reported without NODE_V8_COVERAGE present', (t) => {
78
80
}
79
81
80
82
const fixture = fixtures . path ( 'test-runner' , 'coverage.js' ) ;
81
- const args = [ '--test-coverage' , fixture ] ;
83
+ const args = [ '--experimental- test-coverage' , fixture ] ;
82
84
const result = spawnSync ( process . execPath , args ) ;
83
85
const report = [
84
86
'# start of coverage report' ,
0 commit comments