Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update exists-sync. Add relative path test. #82

Merged
merged 2 commits into from
Nov 4, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"blank-object": "^1.0.1",
"broccoli-plugin": "^1.0.0",
"debug": "^2.2.0",
"exists-sync": "0.0.3",
"exists-sync": "0.0.4",
"fast-ordered-set": "^1.0.0",
"fs-tree-diff": "^0.5.3",
"heimdalljs": "^0.2.0",
Expand Down
17 changes: 17 additions & 0 deletions tests/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,23 @@ describe('broccoli-funnel', function(){
});
});

it('properly supports relative path input node', function() {
var assertions = 0;

var node = new Funnel('../broccoli-funnel', {
destDir: 'foo'
});

builder = new broccoli.Builder(node);
return builder.build()
.catch(function(error) {
assertions++;
})
.then(function() {
expect(assertions).to.equal(0, 'Build did not throw an error, relative path traversal worked.');
});
});

it('throws error on unspecified allowEmpty', function() {
var assertions = 0;
var inputPath = FIXTURE_INPUT + '/dir1';
Expand Down