Closed Bug 444307 Opened 16 years ago Closed 16 years ago

Page Style functions cleanup

Categories

(Firefox :: Menus, defect)

defect
Not set
trivial

Tracking

()

RESOLVED FIXED
Firefox 3.1a2

People

(Reporter: dao, Assigned: dao)

References

Details

Attachments

(1 file)

Attached patch patchSplinter Review
Array.some / Array.slice instead of for-loops, and some minor drive-by cleanup.
Attachment #328648 - Flags: review?(gavin.sharp)
Comment on attachment 328648 [details] [diff] [review]
patch

Can you write a test for this while you're at it? A browser chrome test that loads a page that references a bunch of stylesheets (ideally hitting as many of the code paths as possible), and then call stylesheetFillPopup and check that the menu is populated correctly, maybe? Similar to browser/base/content/test/browser_autodiscovery.js I guess.
Attachment #328648 - Flags: review?(gavin.sharp) → review+
Blocks: 448669
These tests certainly don't cover everything, they are merely a start...
http://hg.mozilla.org/index.cgi/mozilla-central/rev/e270d0ae94b7
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 3.1a2
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: