diff --git a/test/helpers.js b/test/helpers.js index 61e7a6e6..777eeb0e 100644 --- a/test/helpers.js +++ b/test/helpers.js @@ -13,6 +13,20 @@ describe("helpers", function(){ done() }) + it("should collide if output path is .", function(done){ + helpers.willCollide(".", ".").should.be.true + helpers.willCollide("/foo/bar/myproject", ".").should.be.true + helpers.willCollide("/foo/bar/myproject/", ".").should.be.true + done() + }) + + it("should collide if output path is ./", function(done){ + helpers.willCollide("./", "./").should.be.true + helpers.willCollide("/foo/bar/myproject", "./").should.be.true + helpers.willCollide("/foo/bar/myproject/", "./").should.be.true + done() + }) + it("should not collide if output path is /output", function(done){ helpers.willCollide("/foo/bar/myproject", "/output").should.be.false helpers.willCollide("/foo/bar/myproject", "/output/").should.be.false