Skip to content

Commit

Permalink
Use process.cwd as config.rootDir fallback
Browse files Browse the repository at this point in the history
  • Loading branch information
hudochenkov committed Oct 2, 2017
1 parent 7aa3017 commit 3b72383
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/jest-config/src/read_config_file_and_set_root_dir.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ export default (configPath: Path): InitialOptions => {
);
}
} else {
// If rootDir is not there, we'll set it to this file's __dirname
configObject.rootDir = path.dirname(configPath);
// If rootDir is not there, we'll set it to cwd
configObject.rootDir = process.cwd();
}

return configObject;
Expand Down

0 comments on commit 3b72383

Please sign in to comment.