Commit 606c4b2e authored by Paolo Greppi's avatar Paolo Greppi

New upstream version 1.0.1

parent c032f47b
......@@ -3,6 +3,6 @@ language: node_js
node_js:
- node
- '6'
- '5'
- '4'
- '0.12'
- '0.10'
......@@ -2,8 +2,11 @@
environment:
matrix:
# node.js
- nodejs_version: "8.0"
- nodejs_version: "6.0"
- nodejs_version: "5.0"
- nodejs_version: "4.0"
- nodejs_version: "0.12"
- nodejs_version: "0.10"
# Install scripts. (runs after repo cloning)
install:
......
{
"name": "resolve-dir",
"description": "Resolve a directory that is either local, global or in the user's home directory.",
"version": "1.0.0",
"version": "1.0.1",
"homepage": "https://github.com/jonschlinkert/resolve-dir",
"author": "Jon Schlinkert (https://github.com/jonschlinkert)",
"repository": "jonschlinkert/resolve-dir",
......@@ -21,11 +21,12 @@
},
"dependencies": {
"expand-tilde": "^2.0.0",
"global-modules": "^0.2.3"
"global-modules": "^1.0.0"
},
"devDependencies": {
"gulp-format-md": "^0.1.9",
"mocha": "^2.5.3"
"gulp-format-md": "^1.0.0",
"homedir-polyfill": "^1.0.1",
"mocha": "^3.5.0"
},
"keywords": [
"dir",
......
......@@ -8,7 +8,8 @@
'use strict';
require('mocha');
var os = require('os');
var path = require('path');
var homedir = require('homedir-polyfill');
var assert = require('assert');
var gm = require('global-modules');
var resolve = require('./');
......@@ -19,12 +20,12 @@ describe('resolve', function() {
});
it('should resolve the path to user home:', function() {
assert.equal(resolve('~'), os.homedir());
assert.equal(resolve('~/foo'), os.homedir() + '/foo');
assert.equal(resolve('~'), homedir());
assert.equal(resolve('~/foo'), path.join(homedir(), '/foo'));
});
it('should resolve the path to global npm modules:', function() {
assert.equal(resolve('@'), gm);
assert.equal(resolve('@/foo'), gm + '/foo');
assert.equal(resolve('@/foo'), path.join(gm, '/foo'));
});
});
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment