3 ms·
Thanks for the feedback! I've spent a lot of time trying to add tests but ran into a ton of problems trying to get Jest's useFakeTimers and promises to play we
by arrow7000 6y ago
Thanks for the feedback!
I've spent a lot of time trying to add tests but ran into a ton of problems trying to get Jest's useFakeTimers and promises to play well together. I will take another crack at to see if I can work around the problems this time.
Not sure I understand what you mean by returning the promise directly?
Could you explain a bit more why using sets or linked lists would help with efficiency here?
Thanks I'll check out your playlist!
- joshribakoff 6y agoRe: jest, make sure to flush the event queue! Eg await Promise.resolve() which causes the test to pause while all promises queued by the code under test up until that point flush