Closed Bug 787984 Opened 12 years ago Closed 12 years ago

Add tests for imContentSink.jsm

Categories

(Thunderbird :: Instant Messaging, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Thunderbird 18.0

People

(Reporter: florian, Assigned: florian)

Details

Attachments

(1 file, 1 obsolete file)

imContentSink.jsm is the file where we filter out unwanted content from received messages before displaying them, so we should really not let regressions slip into it.
Attached patch WIP (obsolete) — Splinter Review
Attached patch Patch v2Splinter Review
Mike, I think you wrote way more unit tests than Patrick and me, so I'm wondering if you would have some interesting feedback to offer on this. Note for the code review: The change to newRuleset is just some cleanup. The change to cleanupNode fixes https://bugzilla.instantbird.org/show_bug.cgi?id=962.
Attachment #657887 - Attachment is obsolete: true
Attachment #657938 - Flags: review?(clokep)
Attachment #657938 - Flags: feedback?(mconley)
Comment on attachment 657938 [details] [diff] [review] Patch v2 + // Allow id only with numbers. + addGlobalAllowedAttribute("id", function(aId) /^[0-9]+$/.test(aId)); Not /^\d+$/? Besides that it looks OK (and all the tests pass ;)). As far as I can tell this should be a pretty thorough test of the content sink.
Attachment #657938 - Flags: review?(clokep) → review+
Comment on attachment 657938 [details] [diff] [review] Patch v2 Review of attachment 657938 [details] [diff] [review]: ----------------------------------------------------------------- Looks OK to me.
Attachment #657938 - Flags: feedback?(mconley) → feedback+
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 18.0
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: