Add testcases for DOM4 exception types

RESOLVED FIXED in mozilla15

Status

()

Core
DOM
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: emk, Assigned: emk)

Tracking

Trunk
mozilla15
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 2 obsolete attachments)

Comment hidden (empty)
(Assignee)

Comment 1

5 years ago
Created attachment 615099 [details] [diff] [review]
patch
Assignee: nobody → VYV03354
Status: NEW → ASSIGNED
Attachment #615099 - Flags: review?(jonas)
Comment on attachment 615099 [details] [diff] [review]
patch

Review of attachment 615099 [details] [diff] [review]:
-----------------------------------------------------------------

r=me with that change. Yay!

::: content/base/test/file_bug416317.xhtml
@@ +494,5 @@
>            return root[select](q, resolver);
>          } catch(e){
> +          if ( e.message.indexOf("ERR") > -1 ||
> +              e.name == "NamespaceError" && e.code == DOMException.NAMESPACE_ERR ||
> +              e.name == "SyntaxError" && e.code == DOMException.SYNTAX_ERR)

Please don't rely on the fact that && has higher precedence than || since that's not obvious to everyone. So add some parenthesis here.

@@ +548,5 @@
>              try {
>                results = query(q, resolver);
>              } catch(e) {
> +              pass = (e.message === "bad ERROR" ||
> +                      e.name == "NamespaceError" && e.code == DOMException.NAMESPACE_ERR);

Same here
Attachment #615099 - Flags: review?(jonas) → review+
(Assignee)

Comment 3

5 years ago
Created attachment 618253 [details] [diff] [review]
patch for check in
Attachment #615099 - Attachment is obsolete: true
Attachment #618253 - Flags: review+
(Assignee)

Updated

5 years ago
Keywords: checkin-needed
content/test/unit/test_range.js appears to be bitrotted. Please rebase.
Keywords: checkin-needed
(Assignee)

Comment 5

5 years ago
Created attachment 618651 [details] [diff] [review]
patch for check in; r=jonas

Conflicted with bug 702948. Rebased.
Attachment #618253 - Attachment is obsolete: true
Attachment #618651 - Flags: review+
(Assignee)

Updated

5 years ago
Keywords: checkin-needed
https://hg.mozilla.org/integration/mozilla-inbound/rev/bafdd54189ee
Keywords: checkin-needed
Target Milestone: --- → mozilla15

Comment 7

5 years ago
https://hg.mozilla.org/mozilla-central/rev/bafdd54189ee
Status: ASSIGNED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.