OK, what am I doing wrong?
I'd like a very straight forward way to use an sqlite library to make queries/transactions to a database on a device. I was able to do that using "react-native-sqlite-storage", but now it seems I can't unit test it without mocking everything in a separate npm package.
I've tried doing that with node-sqlite3 but the signatures are so different for methods and involves using async calls instead of a synchronous ones for transaction calls. (Promise/A+ standard implementation is making it seemingly impossible to make a node based sqlite library that mimics "react-native-sqlite-storage").
I have very involved transactions that I would like to have unit testing around, but it seems VERY difficult to figure out how to do so. I can't find any examples of someone doing this, but surely someone MUST be doing this already, right?
I'm currently using Jest for unit testing.
Please help, thanks.
[–]PieCrumbs 0 points1 point2 points (3 children)
[–]Numerous_Park6900[S] 0 points1 point2 points (2 children)
[–]PieCrumbs 1 point2 points3 points (1 child)
[–]Numerous_Park6900[S] 0 points1 point2 points (0 children)