You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed some manual sinon.restore calls were occasionally slipping through PR reviews within our teams, even though there is no need for it with this addon.
The following ESLint rule detects those and catches them upfront:
rules: {'no-restricted-syntax': ['error',{message: "Restoring the sandbox is handled automatically by 'ember-sinon-qunit'.",selector: 'MemberExpression[object.name="sinon"][property.name="restore"]',},],// ... other rules},// ... other config options
Just putting this out here in case it would be helpful to others.
As next steps, I suppose this could be:
Added to the readme/docs
Or made into an actual lightweight ESLint plugin which consumers could include in their own config
The text was updated successfully, but these errors were encountered:
Hey 👋
I noticed some manual
sinon.restore
calls were occasionally slipping through PR reviews within our teams, even though there is no need for it with this addon.The following ESLint rule detects those and catches them upfront:
Just putting this out here in case it would be helpful to others.
As next steps, I suppose this could be:
The text was updated successfully, but these errors were encountered: