Hi Hackers,<p>I have been struggling a lot to mock database in one of my side projects while writing junits. Can somebody please help me out here. Below is what the scenario looks like:<p>Before that, the source code is here - https://github.com/sunilkumarc/track-courier<p>1. I have created a model using sequelize module in Nodejs. And I access my db through this model.<p>2. I want to mock the db calls when running junits. For example fineOne method here which return a promise. (https://github.com/sunilkumarc/track-courier/blob/master/models/parcels.js#L4). Basically when running this particular endpoint I want to skip accessing the db.<p>Any help is appreciated!<p>Regards,
Sunil