Skip to content

Commit

Permalink
quote test folder path
Browse files Browse the repository at this point in the history
Redo #1083
  • Loading branch information
Daniel Schmidt committed Jan 29, 2019
1 parent 9c401ca commit 5ff5dfd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion detox/local-cli/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ module.exports.handler = function main(program) {
const platformString = platform ? shellQuote(`--testNamePattern=^((?!${getPlatformSpecificString(platform)}).)*$`) : '';
const binPath = path.join('node_modules', '.bin', 'jest');
const color = program.color ? '' : ' --no-color';
const command = `${binPath} ${testFolder} ${configFile}${color} --maxWorkers=${program.workers} ${platformString} ${collectExtraArgs()}`;
const command = `${binPath} "${testFolder}" ${configFile}${color} --maxWorkers=${program.workers} ${platformString} ${collectExtraArgs()}`;
const detoxEnvironmentVariables = {
configuration: program.configuration,
loglevel: program.loglevel,
Expand Down
3 changes: 2 additions & 1 deletion detox/local-cli/test.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,10 @@ describe('test', () => {
} catch (e) {
console.log(e);
}

expect(mockExec).toHaveBeenCalledWith(
expect.stringContaining(
"node_modules/.bin/jest e2e --config=e2e/config.json --no-color --maxWorkers=1 '--testNamePattern=^((?!:ios:).)*$'"
`node_modules/.bin/jest \"e2e\" --config=e2e/config.json --no-color --maxWorkers=1 \'--testNamePattern=^((?!:ios:).)*$\'`
),
expect.anything()
);
Expand Down

0 comments on commit 5ff5dfd

Please sign in to comment.