Are there any worthwhile alternatives for Sinon.js?
Thanks.
There is also library called testdouble.js. Which is a kind of more object-oriented than sinon.js.
Also, this article from testdouble guys explain the differences between sinon.js and testdouble.js.
var td = require('testdouble');
var fetch = td.function();
td.when(fetch(42)).thenReturn('Jane User');
fetch(42); // -> 'Jane User'
Not quite as advanced, but you can look at Jack.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With