You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: lib/config-util.js
+42-21
Original file line number
Diff line number
Diff line change
@@ -98,105 +98,126 @@ Config.buildYargs = function (cwd) {
98
98
.option('reporter',{
99
99
alias: 'r',
100
100
describe: 'coverage reporter(s) to use',
101
-
default: 'text'
101
+
default: 'text',
102
+
globa: false
102
103
})
103
104
.option('report-dir',{
104
105
describe: 'directory to output coverage reports in',
105
-
default: 'coverage'
106
+
default: 'coverage',
107
+
global: false
106
108
})
107
109
.option('silent',{
108
110
alias: 's',
109
111
default: false,
110
112
type: 'boolean',
111
-
describe: "don't output a report after tests finish running"
113
+
describe: "don't output a report after tests finish running",
114
+
global: false
112
115
})
113
116
.option('all',{
114
117
alias: 'a',
115
118
default: false,
116
119
type: 'boolean',
117
-
describe: 'whether or not to instrument all files of the project (not just the ones touched by your test suite)'
120
+
describe: 'whether or not to instrument all files of the project (not just the ones touched by your test suite)',
121
+
global: false
118
122
})
119
123
.option('exclude',{
120
124
alias: 'x',
121
125
default: testExclude.defaultExclude,
122
-
describe: 'a list of specific files and directories that should be excluded from coverage, glob patterns are supported, node_modules is always excluded'
126
+
describe: 'a list of specific files and directories that should be excluded from coverage, glob patterns are supported, node_modules is always excluded',
127
+
global: false
123
128
})
124
129
.option('include',{
125
130
alias: 'n',
126
131
default: [],
127
-
describe: 'a list of specific files that should be covered, glob patterns are supported'
132
+
describe: 'a list of specific files that should be covered, glob patterns are supported',
133
+
global: false
128
134
})
129
135
.option('require',{
130
136
alias: 'i',
131
137
default: [],
132
-
describe: 'a list of additional modules that nyc should attempt to require in its subprocess, e.g., babel-register, babel-polyfill.'
138
+
describe: 'a list of additional modules that nyc should attempt to require in its subprocess, e.g., babel-register, babel-polyfill.',
139
+
global: false
133
140
})
134
141
.option('eager',{
135
142
default: false,
136
143
type: 'boolean',
137
-
describe: 'instantiate the instrumenter at startup (see https://git.io/vMKZ9)'
144
+
describe: 'instantiate the instrumenter at startup (see https://git.io/vMKZ9)',
145
+
global: false
138
146
})
139
147
.option('cache',{
140
148
alias: 'c',
141
149
default: true,
142
150
type: 'boolean',
143
-
describe: 'cache instrumentation results for improved performance'
151
+
describe: 'cache instrumentation results for improved performance',
152
+
global: false
144
153
})
145
154
.option('babel-cache',{
146
155
default: false,
147
156
type: 'boolean',
148
-
describe: 'cache babel transpilation results for improved performance'
157
+
describe: 'cache babel transpilation results for improved performance',
158
+
global: false
149
159
})
150
160
.option('extension',{
151
161
alias: 'e',
152
162
default: [],
153
-
describe: 'a list of extensions that nyc should handle in addition to .js'
163
+
describe: 'a list of extensions that nyc should handle in addition to .js',
164
+
global: false
154
165
})
155
166
.option('check-coverage',{
156
167
type: 'boolean',
157
168
default: false,
158
-
describe: 'check whether coverage is within thresholds provided'
169
+
describe: 'check whether coverage is within thresholds provided',
170
+
global: false
159
171
})
160
172
.option('branches',{
161
173
default: 0,
162
-
description: 'what % of branches must be covered?'
174
+
description: 'what % of branches must be covered?',
175
+
global: false
163
176
})
164
177
.option('functions',{
165
178
default: 0,
166
-
description: 'what % of functions must be covered?'
179
+
description: 'what % of functions must be covered?',
180
+
global: false
167
181
})
168
182
.option('lines',{
169
183
default: 90,
170
-
description: 'what % of lines must be covered?'
184
+
description: 'what % of lines must be covered?',
185
+
global: false
171
186
})
172
187
.option('statements',{
173
188
default: 0,
174
-
description: 'what % of statements must be covered?'
189
+
description: 'what % of statements must be covered?',
190
+
global: false
175
191
})
176
192
.option('source-map',{
177
193
default: true,
178
194
type: 'boolean',
179
-
description: 'should nyc detect and handle source maps?'
195
+
description: 'should nyc detect and handle source maps?',
196
+
global: false
180
197
})
181
198
.option('produce-source-map',{
182
199
default: false,
183
200
type: 'boolean',
184
-
description: "should nyc's instrumenter produce source maps?"
201
+
description: "should nyc's instrumenter produce source maps?",
0 commit comments