Skip to content
This repository was archived by the owner on Dec 15, 2022. It is now read-only.

Commit 70f8028

Browse files
remove stub restores
1 parent 6a34a52 commit 70f8028

File tree

2 files changed

+1
-9
lines changed

2 files changed

+1
-9
lines changed

test/containers/comment-decorations-container.test.js

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,6 @@ describe('CommentDecorationsContainer', function() {
187187
const stub = sinon.stub(console, 'warn');
188188
const resultWrapper = tokenWrapper.find(QueryRenderer).renderProp('render')({
189189
error: 'oh noes', props: null, retry: () => {}});
190-
stub.restore();
191190
assert.isTrue(resultWrapper.isEmptyRender());
192191
});
193192

@@ -263,8 +262,6 @@ describe('CommentDecorationsContainer', function() {
263262
commentThreads: [],
264263
});
265264

266-
stub.restore();
267-
268265
assert.isTrue(reviewsWrapper.isEmptyRender());
269266
});
270267

@@ -350,7 +347,6 @@ describe('CommentDecorationsContainer', function() {
350347
const patchWrapper = reviewsWrapper.find(PullRequestPatchContainer).renderProp('children')(
351348
new Error('oops'), null,
352349
);
353-
stub.restore();
354350
assert.isTrue(patchWrapper.isEmptyRender());
355351
});
356352

test/containers/issueish-search-container.test.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ describe('IssueishSearchContainer', function() {
9090
describe('when the query errors', function() {
9191
let stub;
9292
// Consumes the failing Relay Query console error
93-
before(function() {
93+
beforeEach(function() {
9494
stub = sinon.stub(console, 'error');
9595
// eslint-disable-next-line no-console
9696
console.error.withArgs(
@@ -126,10 +126,6 @@ describe('IssueishSearchContainer', function() {
126126
assert.deepEqual(controller.prop('error').errors, [{message: 'uh oh'}]);
127127
assert.lengthOf(controller.prop('results'), 0);
128128
});
129-
130-
after(function() {
131-
stub.restore();
132-
});
133129
});
134130

135131
it('passes results to the controller', async function() {

0 commit comments

Comments
 (0)