Closed Bug 1178391 Opened 9 years ago Closed 9 years ago

Countdown to zero warnings in shared test suite

Categories

(Hello (Loop) :: Client, defect, P2)

defect

Tracking

(firefox42 fixed)

RESOLVED FIXED
mozilla42
Iteration:
42.1 - Jul 13
Tracking Status
firefox42 --- fixed

People

(Reporter: mikedeboer, Assigned: andreio)

References

Details

(Whiteboard: [test][tech-debt])

Attachments

(1 file, 2 obsolete files)

Currently: 156 warnings in total. Goal: 0.
Flags: qe-verify-
Flags: firefox-backlog+
Assignee: nobody → andrei.br92
Iteration: --- → 42.1 - Jul 13
Rank: 26
Priority: -- → P2
Whiteboard: [test][tech-debt]
Attached patch Fix all warnings in Loop shared test suite (obsolete) (deleted) — Splinter Review
Attached patch Fix all warnings in Loop shared test suite (obsolete) (deleted) — Splinter Review
Attachment #8630286 - Attachment is obsolete: true
Attachment #8630338 - Flags: review?(standard8)
Comment on attachment 8630338 [details] [diff] [review] Fix all warnings in Loop shared test suite Review of attachment 8630338 [details] [diff] [review]: ----------------------------------------------------------------- This is almost there, I'd just like to give it another once over when you've addressed the comments. ui-showcase.jsx and standalone/index.html both needs their counts updating. ::: browser/components/loop/test/shared/activeRoomStore_test.js @@ +19,5 @@ > sandbox.useFakeTimers(); > > dispatcher = new loop.Dispatcher(); > sandbox.stub(dispatcher, "dispatch"); > + closeWindowStub = sandbox.stub(window, "close"); I don't think we need the specific stub names here. Although its an alias, something like sinon.assert.calledOnce(window.close) is pretty obvious its been stubbed, and imho its easier to work out at a glance. @@ +1185,5 @@ > + > + it("should log an error in the console", function() { > + listener(new Error("foo")); > + > + sinon.assert.calledOnce(errorStub); ditto here with the errorStub name. ::: browser/components/loop/test/shared/conversationStore_test.js @@ +357,5 @@ > .eql(sharedUtils.CALL_TYPES.AUDIO_VIDEO); > }); > > describe("incoming calls", function() { > + var consoleErrorStub; Ditto wrt not needing to alias names in this file & the other test files (additionally some of these aliases aren't actually used). ::: browser/components/loop/test/shared/utils_test.js @@ +339,5 @@ > }); > + > + it("should log an error message to the console", function() { > + // Stub to prevent console messages > + var errorStub = sandbox.stub(window.console, "error"); Lets drop the alias, and take the stub up to a beforeEach as its used in two tests next to each other.
Attachment #8630338 - Flags: review?(standard8) → review-
Attachment #8630338 - Attachment is obsolete: true
Attachment #8631276 - Flags: review?(standard8)
Comment on attachment 8631276 [details] [diff] [review] Fix all warnings in Loop shared test suite Review of attachment 8631276 [details] [diff] [review]: ----------------------------------------------------------------- That's great. I'll land this for you now since I've got some other patches that are likely to conflict with this.
Attachment #8631276 - Flags: review?(standard8) → review+
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla42
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: