Closed Bug 601277 Opened 14 years ago Closed 12 years ago

Write tests for document.domain

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla16
Tracking Status
blocking2.0 --- -
status2.0 --- wanted

People

(Reporter: mounir, Assigned: mounir)

References

Details

Attachments

(1 file, 2 obsolete files)

      No description provided.
Attached patch Tests (obsolete) — Splinter Review
Attachment #482208 - Flags: review?(jst)
FWIW, these tests are no longer working.
We'll need this test when mrbkap works on further document.domain related changes for beta8, so marking a blocker.
blocking2.0: --- → beta8+
We don't need to worry about this for beta8, pushing to beta9.
blocking2.0: beta8+ → beta9+
As per today's meeting, beta 9 will be a time-based release. Marking these all betaN+. Please move it back to beta9+ if  you believe it MUST be in the next beta (ie: trunk is in an unshippable state without this)
blocking2.0: beta9+ → betaN+
Re-setting the CC list assuming this change wasn't intentional.
Fixing fields my automated script accidentally blanked. Apologies for the bugspam
Whiteboard: hardblocker
Whiteboard: hardblocker → [hardblocker]
I'm keeping this as a blocker because I believe in test driven development yatta yatta, but tests don't need permission for approval so I question whether or not this even needs soft blocking status.

It needs to be done, absolutely, but does it need to keep us from shipping? I assert not!
Whiteboard: [hardblocker] → [softblocker]
Attached patch Tests (obsolete) — Splinter Review
Updated tests to make sure the test actually finish on trunk (currently 8 passes and 10 fails).
Attachment #482208 - Attachment is obsolete: true
Attachment #482208 - Flags: review?(jst)
(In reply to comment #8)
> I'm keeping this as a blocker because I believe in test driven development
> yatta yatta, but tests don't need permission for approval so I question whether
> or not this even needs soft blocking status.

FWIW, the real purpose of the bug is to make trunk pass this test.
We're past feature freeze.  This sounds like a non-blocker to me.
blocking2.0: betaN+ → ?
Whiteboard: [softblocker]
Yeah, we should get these tests in in a form where they pass, but we did change our minds on what the exact security policy is wrt document.domain. Either way, this is not a blocker any more due to the policy change.
blocking2.0: ? → -
status2.0: --- → wanted
Depends on: 729150
Attached patch Better tests. v1Splinter Review
I spent some time with the tests on the bug this morning and found them inscrutable and impossible to extend. Here are some much cleaner ones.
Attachment #507485 - Attachment is obsolete: true
Attachment #637462 - Flags: review?(mrbkap)
Note that we're now explicitly testing for the behavior I proposed here: http://lists.w3.org/Archives/Public/public-script-coord/2012AprJun/0120.html
Comment on attachment 637462 [details] [diff] [review]
Better tests. v1

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

::: js/xpconnect/tests/chrome/test_documentdomain.xul
@@ +32,5 @@
> +  function startTest() {
> +
> +    // Grab all the content windows. We waive Xray here, and add it back with
> +    // XPCNativeWrapper whenever we pass references into content.
> +    var win1A = document.getElementById('test1A').contentWindow.wrappedJSObject;

All of this futzing around with .wrappedJSObject and XPCNativeWrapper shouldn't matter for the case where we're passing object around... I think you should be able to nuke it.
Attachment #637462 - Flags: review?(mrbkap) → review+
https://hg.mozilla.org/mozilla-central/rev/c9b038fa6956
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla16
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: