Skip to content
This repository has been archived by the owner on Jul 23, 2021. It is now read-only.

Commit

Permalink
path.existsSync is deprecated. It is now called fs.existsSync.
Browse files Browse the repository at this point in the history
  • Loading branch information
nilbus authored and mhevery committed Dec 5, 2012
1 parent d001c11 commit 80e4362
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
3 changes: 2 additions & 1 deletion lib/jasmine-node/autotest.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,8 @@ var watchFile = function(file, stat) {

var watcher = fs.watch(file, function(ev) {

if(!path.existsSync(file)) {
var existsSync = fs.existsSync || path.existsSync;
if(!existsSync(file)) {
watcher.close();
return;
}
Expand Down
3 changes: 2 additions & 1 deletion lib/jasmine-node/cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@ while(args.length) {
case '--test-dir':
var dir = args.shift();

if(!Path.existsSync(dir))
var existsSync = fs.existsSync || path.existsSync;
if(!existsSync(dir))
throw new Error("Test root path '" + dir + "' doesn't exist!");

specFolder = dir; // NOTE: Does not look from current working directory.
Expand Down
3 changes: 2 additions & 1 deletion lib/jasmine-node/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,8 @@ jasmine.executeSpecsInFolder = function(folder,
specs.load(folder, fileMatcher);

if(junitreport && junitreport.report) {
if(!path.existsSync(junitreport.savePath)) {
var existsSync = fs.existsSync || path.existsSync;
if(!existsSync(junitreport.savePath)) {
util.puts('creating junit xml report save path: ' + junitreport.savePath);
fs.mkdirSync(junitreport.savePath, "0755");
}
Expand Down

0 comments on commit 80e4362

Please sign in to comment.