Refactor suite timing out of Env and into each Reporter
[finishes #45659879]
This commit is contained in:
13
spec/core/TimerSpec.js
Normal file
13
spec/core/TimerSpec.js
Normal file
@@ -0,0 +1,13 @@
|
||||
describe("Timer", function() {
|
||||
it("reports the time elapsed", function() {
|
||||
var fakeNow = jasmine.createSpy('fake Date.now'),
|
||||
timer = new j$.Timer({now: fakeNow});
|
||||
|
||||
fakeNow.andReturn(100);
|
||||
timer.start();
|
||||
|
||||
fakeNow.andReturn(200);
|
||||
|
||||
expect(timer.elapsed()).toEqual(100);
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user