Created
August 2, 2016 04:23
-
-
Save ClayShentrup/48102fb34dfefc7f316e5285ba04b85e to your computer and use it in GitHub Desktop.
Stubbing Jasmine time
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
beforeEach(function () { | |
jasmine.clock().install(); | |
jasmine.clock().mockDate( | |
new Date(2015, 4, 20) | |
); | |
}); | |
afterEach(function () { | |
jasmine.clock().uninstall(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment