How do I use AVA to test a library that registers an unhandledRejection
callback:
process.on('unhandledRejection', e =>
// do something effectful
);
In this environment, unhandled rejections are not necessarily errors in the library. I want to ensure that my library is robust against users' callbacks causing an unhandled rejection.
Without a way to do this, I have to use a different testing framework (like Tape) to execute those tests.