Skip to content

Commit

Permalink
Merge pull request #41 from errorception/tests
Browse files Browse the repository at this point in the history
Add one more test about `includeAll` option
  • Loading branch information
rakeshpai committed Sep 30, 2019
2 parents 5fc3d7e + f41f5cf commit a36b31b
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion test/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,14 @@ describe('constructor', () => {
});

describe('Options work', () => {
it('`ignoreAll: false` works', () => {
it('`includeAll: false` works', () => {
const versions = staticify(ROOT)._versions;
const matches = Object.keys(versions).filter(ver => ver.match(/node_modules|\.git/)).length === 0;

matches.should.be.false();
});

it('`includeAll: true` works', () => {
const versions = staticify(ROOT, {includeAll: true})._versions;
const matches = Object.keys(versions).filter(ver => ver.match(/node_modules|\.git/)).length > 0;

Expand Down

0 comments on commit a36b31b

Please sign in to comment.