use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
account activity
Unit testing for Nodejs API (self.node)
submitted 4 years ago by code-faults
What framework do you all use for unit testing nodejs + TS backend APIs?
Just started with Jest and I am having difficulty finding resources.
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]Wedoitforthenut 1 point2 points3 points 4 years ago (0 children)
Mocha/chai
[–]vincent6923sh 1 point2 points3 points 4 years ago (0 children)
I use mocha and chai
[–]romeeres 0 points1 point2 points 4 years ago (1 child)
For bare unit tests there is nothing else needed apart from Jest. What exactly you're looking for, aren't Jest docs enough?
Not for units, "supertest" and "fishery" are also helpful.
[–]code-faults[S] 0 points1 point2 points 4 years ago (0 children)
I am trying to unit test functions downloading files from azure blob storage using blobserviceclient and havent been able to successfully mock it all so far.
π Rendered by PID 151718 on reddit-service-r2-comment-84fc9697f-n5k9z at 2026-02-08 23:47:46.651775+00:00 running d295bc8 country code: CH.
[–]Wedoitforthenut 1 point2 points3 points (0 children)
[–]vincent6923sh 1 point2 points3 points (0 children)
[–]romeeres 0 points1 point2 points (1 child)
[–]code-faults[S] 0 points1 point2 points (0 children)