mocha test passes even though I throw error
it.only(‘test’, async() => { const lol = pdfjs.getDocument({data: data, password: "123"}) lol.promise.then((ex) => { return ex }).catch((err) => { console.log(err) throw err; }); }); in this block of code "err" is being printed, and the test passes. also tried – assert.fail(‘expected’, ‘actual’, err); and done(). nothing worked, test is still passing every time. why is… Read More mocha test passes even though I throw error