Projects
openEuler:24.03:SP1:Everything
nodeunit
_service:tar_scm:nodeunit-0.9.1-Use-fs-stat.patch
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:tar_scm:nodeunit-0.9.1-Use-fs-stat.patch of Package nodeunit
commit a796685799f368964d76c788e6d41ca7dc59c295 Author: Tom Hughes <tom@compton.nu> Date: Wed Jan 20 18:12:26 2016 +0000 Replace path.exists with fs.stat diff --git a/test/test-runfiles.js b/test/test-runfiles.js index ecbdfd8..2c276de 100644 --- a/test/test-runfiles.js +++ b/test/test-runfiles.js @@ -1,6 +1,5 @@ var assert = require('assert'), fs = require('fs'), - path = require('path'), nodeunit = require('../lib/nodeunit'); @@ -116,8 +115,8 @@ exports.testEmptyDir = function (test) { var dir2 = __dirname + '/fixtures/dir2'; // git doesn't like empty directories, so we have to create one - path.exists(dir2, function (exists) { - if (!exists) { + fs.stat(dir2, function (err) { + if (err) { fs.mkdirSync(dir2, 0777); }
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.
浙ICP备2022010568号-2