is-absolute
Advanced tools
Comparing version 0.1.2 to 0.1.3
{ | ||
"name": "is-absolute", | ||
"version": "0.1.2", | ||
"version": "0.1.3", | ||
"main": [ | ||
@@ -5,0 +5,0 @@ "index.js" |
@@ -10,2 +10,4 @@ /*! | ||
var isRelative = require('is-relative'); | ||
/** | ||
@@ -38,2 +40,6 @@ * **Example:** | ||
} | ||
}; | ||
if (!isRelative(filepath)) { | ||
return true; | ||
} | ||
}; | ||
{ | ||
"name": "is-absolute", | ||
"description": "Return true if a file path is absolute.", | ||
"version": "0.1.2", | ||
"version": "0.1.3", | ||
"homepage": "https://github.com/jonschlinkert/is-absolute", | ||
@@ -24,9 +24,16 @@ "author": { | ||
"keywords": [ | ||
"docs", | ||
"documentation", | ||
"generate", | ||
"generator", | ||
"markdown", | ||
"templates", | ||
"verb" | ||
"absolute", | ||
"check", | ||
"file", | ||
"filepath", | ||
"is", | ||
"normalize", | ||
"path", | ||
"path.relative", | ||
"relative", | ||
"resolve", | ||
"slash", | ||
"slashes", | ||
"uri", | ||
"url" | ||
], | ||
@@ -45,3 +52,6 @@ "main": "index.js", | ||
"verb-tag-jscomments": ">= 0.1.4" | ||
}, | ||
"dependencies": { | ||
"is-relative": "^0.1.0" | ||
} | ||
} |
@@ -10,3 +10,3 @@ /*! | ||
var expect = require('chai').expect; | ||
var assert = require('assert'); | ||
var isAbsolute = require('../'); | ||
@@ -16,19 +16,19 @@ | ||
it('should support windows', function(){ | ||
expect(isAbsolute('c:\\')).to.be.true; | ||
expect(isAbsolute('//C://user\\docs\\Letter.txt')).to.be.true; | ||
expect(!isAbsolute(':\\')).to.be.true; | ||
expect(!isAbsolute('foo\\bar\\baz')).to.be.true; | ||
expect(!isAbsolute('foo\\bar\\baz\\')).to.be.true; | ||
assert(isAbsolute('c:\\')); | ||
assert(isAbsolute('//C://user\\docs\\Letter.txt')); | ||
assert(!isAbsolute(':\\')); | ||
assert(!isAbsolute('foo\\bar\\baz')); | ||
assert(!isAbsolute('foo\\bar\\baz\\')); | ||
}); | ||
it('should support windows unc', function(){ | ||
expect(isAbsolute('\\\\foo\\bar')) | ||
expect(isAbsolute('//UNC//Server01//user//docs//Letter.txt')).to.be.true; | ||
assert(isAbsolute('\\\\foo\\bar')) | ||
assert(isAbsolute('//UNC//Server01//user//docs//Letter.txt')); | ||
}); | ||
it('should support unices', function(){ | ||
expect(isAbsolute('/foo/bar')).to.be.true; | ||
expect(!isAbsolute('foo/bar')).to.be.true; | ||
expect(isAbsolute('/user/docs/Letter.txt')).to.be.true; | ||
assert(isAbsolute('/foo/bar')); | ||
assert(!isAbsolute('foo/bar')); | ||
assert(isAbsolute('/user/docs/Letter.txt')); | ||
}); | ||
}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7643
109
1
+ Addedis-relative@^0.1.0
+ Addedis-relative@0.1.3(transitive)