Currently i am working with Sails and Authy.js API to authenticate new users using authy.verify function. Most of my code is in the callback to create new users.
I am in process of write tests to test my endpoints. What would be the best way to mock authy.verify function so that i can test my code in the callback function ?
I have tried using sinon and testdouble but to no avail.
Any help would be appreciated. Thanks!