Lumin Posted on May 5, 2022 Mock new Date with sinon #javascript #node #sinon #testing const mockNow = new Date() beforeEach(() => { sinon.useFakeTimers(mockNow.getTime()) }) Enter fullscreen mode Exit fullscreen mode Bye Top comments (0) Subscribe Submit Preview Dismiss Code of Conduct • Report abuse
Top comments (0)