diff options
| author | Gerard Escalante <[email protected]> | 2014-02-11 11:10:34 +0900 |
|---|---|---|
| committer | Gerard Escalante <[email protected]> | 2014-02-11 11:10:34 +0900 |
| commit | ab1c7aeda0359fb174e4dbfdb7e117cc029eb329 (patch) | |
| tree | fc7a02bb26f448233c9626704d499cca30c6d327 /test/getOptions.js | |
| parent | 7f7dad83d26e0d3c3326c260926acfcb6e05fa58 (diff) | |
| download | node-coveralls-ab1c7aeda0359fb174e4dbfdb7e117cc029eb329.tar.xz node-coveralls-ab1c7aeda0359fb174e4dbfdb7e117cc029eb329.zip | |
Windows compat fixes
Changed usage of '/' as root dir. Stopped tests from wiping out
environment.
Diffstat (limited to 'test/getOptions.js')
| -rw-r--r-- | test/getOptions.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/getOptions.js b/test/getOptions.js index f9b2494..9e844ec 100644 --- a/test/getOptions.js +++ b/test/getOptions.js @@ -301,7 +301,7 @@ function ensureLocalGitContext(options) { var fs = require('fs'); var baseDir = process.cwd(), dir = baseDir, gitDir; - while ('/' !== dir) { + while (path.resolve('/') !== dir) { gitDir = path.join(dir, '.git'); var existsSync = fs.existsSync || path.existsSync; if (existsSync(path.join(gitDir, 'HEAD'))) @@ -311,7 +311,7 @@ function ensureLocalGitContext(options) { } options = options || {}; - var synthetic = '/' === dir; + var synthetic = path.resolve('/') === dir; var gitHead, content, branch, id, wrapUp = function() {}; if (synthetic) { |
