Update some Sinon reset() calls
In Sinon 2, reset() now resets both behavior and history, so if a stub specifies behavior and we want to use it again, we have to call resetHistory().
This commit is contained in:
parent
522391bc3e
commit
ede03f4366
5 changed files with 12 additions and 11 deletions
|
@ -308,9 +308,6 @@ describe("Zotero.Feed", function() {
|
|||
before(function() {
|
||||
scheduleNextFeedCheck = sinon.stub(Zotero.Feeds, 'scheduleNextFeedCheck');
|
||||
});
|
||||
after(function() {
|
||||
scheduleNextFeedCheck.restore();
|
||||
});
|
||||
|
||||
beforeEach(function* (){
|
||||
scheduleNextFeedCheck.reset();
|
||||
|
@ -323,6 +320,10 @@ describe("Zotero.Feed", function() {
|
|||
yield clearFeeds();
|
||||
});
|
||||
|
||||
after(function() {
|
||||
scheduleNextFeedCheck.restore();
|
||||
});
|
||||
|
||||
it('should schedule next feed check', function* () {
|
||||
|
||||
let feed = yield createFeed();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue