Skip to content

Commit

Permalink
Merge pull request #200 from merrywhether/test-tweaks
Browse files Browse the repository at this point in the history
chore(tests): ensure name/logic matches
  • Loading branch information
yowainwright committed May 23, 2024
2 parents 951cd46 + 3ebd311 commit 2f8e79b
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions test.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ it('👌 Es Check should fail when checking an array of es6 files as es5', (don
})
})

it('🎉 Es Check should pass when checking a glob of es6 files ', (done) => {
it('🎉 Es Check should pass when checking a glob of es6 files as es6', (done) => {
exec('node index.js es6 "./tests/*.js"', (err, stdout, stderr) => {
if (err) {
console.error(err.stack)
Expand All @@ -58,24 +58,24 @@ it('👌 Es Check fails when give an invalid version', (done) => {
})
})

it('👌 Es Check should fail when checking a glob of es5 files', (done) => {
exec('node index.js es5 ./tests/*.js', (err, stdout, stderr) => {
it('👌 Es Check should fail when checking a glob of es6 files as es5', (done) => {
exec('node index.js es5 "./tests/*.js"', (err, stdout, stderr) => {
assert(err)
console.log(stdout)
done()
})
})

it('👌 Es Check should fail when given a glob that matches no files', (done) => {
exec('node index.js es5 ./tests/es5.js foo-bar.js', (err, stdout, stderr) => {
exec('node index.js es5 foo-bar.js', (err, stdout, stderr) => {
assert(err)
console.log(stdout)
done()
})
})

it('👌 Es Check should fail when given a glob that matches files and a glob that does not', (done) => {
exec('node index.js es5 foo-bar.js', (err, stdout, stderr) => {
exec('node index.js es5 ./tests/es5.js foo-bar.js', (err, stdout, stderr) => {
assert(err)
console.log(stdout)
done()
Expand Down

0 comments on commit 2f8e79b

Please sign in to comment.