Fix eslint no-unused-expressions in tests

[MAILPOET-1085]
This commit is contained in:
Pavel Dohnal
2017-09-06 15:41:41 +01:00
parent 72c0a6f165
commit 4e508855fc
6 changed files with 12 additions and 11 deletions

View File

@ -33,7 +33,8 @@ define([
}
});
module.save();
expect(spy.withArgs('beforeEditorSave').calledOnce).to.be.true;
expect(spy).to.have.callCount(1);
expect(spy).to.have.been.calledWith('beforeEditorSave');
});
it('triggers afterEditorSave event', function() {
@ -54,7 +55,7 @@ define([
});
promise.resolve({ success: true });
module.save();
expect(spy.withArgs('afterEditorSave').calledOnce).to.be.true;
expect(spy.withArgs('afterEditorSave').calledOnce).to.be.true;// eslint-disable-line no-unused-expressions
});
it('sends newsletter json to server for saving', function() {
@ -188,7 +189,8 @@ define([
view.render();
view.$('.mailpoet_save_next').click();
expect(spy.withArgs('beforeEditorSave').calledOnce).to.be.true;
expect(spy).to.have.callCount(1);
expect(spy).to.have.been.calledWith('beforeEditorSave');
});
});