Skip to content

Commit

Permalink
[fix] path.existsSync was moved to fs.existsSync
Browse files Browse the repository at this point in the history
  • Loading branch information
blakmatrix committed Jul 7, 2012
1 parent 0097969 commit d0caca1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions test/qpixmap.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,10 @@ var app = new qt.QApplication();
// save()
{
var pixmap = new qt.QPixmap(10, 10);
if (path.existsSync('./__pixmap.png'))
if (fs.existsSync('./__pixmap.png'))
fs.unlinkSync('__pixmap.png');
pixmap.save('__pixmap.png');
assert.equal(path.existsSync('./__pixmap.png'), true, '.save() works');
assert.equal(fs.existsSync('./__pixmap.png'), true, '.save() works');
fs.unlinkSync('./__pixmap.png');
}

Expand Down
4 changes: 2 additions & 2 deletions test/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ var fs = require('fs'),
var testDir = __dirname+'/img-test/',
refDir = __dirname+'/img-ref/';

if (!path.existsSync(testDir)) {
if (!fs.existsSync(testDir)) {
console.log('! regression warning: img-test/ dir does not exist. creating it...')
fs.mkdirSync(testDir);
}
Expand All @@ -15,7 +15,7 @@ exports.regression = function(name, pixmap, callback) {
pixmap.save(testDir+name+'.png');

// Can't compare if refs don't exist
if (!path.existsSync(refDir+name+'.png')) {
if (!fs.existsSync(refDir+name+'.png')) {
console.log('! regression warning: could not find reference file for test:', name)
return;
}
Expand Down

0 comments on commit d0caca1

Please sign in to comment.