Skip to content

Commit

Permalink
test(anagram): test for no anagrams found input too long
Browse files Browse the repository at this point in the history
  • Loading branch information
drawnepicenter committed Aug 26, 2016
1 parent 2dac4dc commit c02989d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion test/test.es6
Original file line number Diff line number Diff line change
Expand Up @@ -1120,7 +1120,7 @@ describe('root commands', () => {
})
})
it('handles no found anagrams', (done) => {
child.exec(`node ${process.cwd()}/build/leximaven.js anagram bcdfghjklmnpqrstvwxz > test/output/anagram.out`, (err) => {
child.exec(`node ${process.cwd()}/build/leximaven.js anagram bcdfghjklmnp > test/output/anagram.out`, (err) => {
const stdout = fs.readFileSync('test/output/anagram.out', 'utf8')
expect(stdout.replace(/(\r\n|\n|\r)\s?/gm, '\n')).to.match(/No anagrams found\./mig)
done(err)
Expand Down
2 changes: 1 addition & 1 deletion test/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -1121,7 +1121,7 @@ describe('root commands', function () {
});
});
it('handles no found anagrams', function (done) {
child.exec('node ' + process.cwd() + '/build/leximaven.js anagram bcdfghjklmnpqrstvwxz > test/output/anagram.out', function (err) {
child.exec('node ' + process.cwd() + '/build/leximaven.js anagram bcdfghjklmnp > test/output/anagram.out', function (err) {
var stdout = fs.readFileSync('test/output/anagram.out', 'utf8');
expect(stdout.replace(/(\r\n|\n|\r)\s?/gm, '\n')).to.match(/No anagrams found\./mig);
done(err);
Expand Down

0 comments on commit c02989d

Please sign in to comment.