File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ function create(settings) {
4343 ] ,
4444 testEnvironment : 'jsdom' ,
4545 testEnvironmentOptions : {
46- url : 'http://localhost' ,
46+ url : 'http://localhost'
4747 } ,
4848 transform : {
4949 // Jest and Babel don't allow functions in the options so we just return their values here
@@ -94,7 +94,9 @@ function create(settings) {
9494}
9595
9696function unit ( settings ) {
97- const argv = process . argv . slice ( 2 ) ;
97+ // slice(3) to skip ['node', 'index.js', 'test'] — the yargs command name
98+ // must not be forwarded to Jest as it becomes a test path pattern
99+ const argv = process . argv . slice ( 3 ) ;
98100 const jestConfig = JSON . stringify ( create ( settings ) ) ;
99101 argv . push ( `--config=${ jestConfig } ` , '--env=jsdom' ) ;
100102
You can’t perform that action at this time.
0 commit comments