Pass W3C websocket test suite

RESOLVED FIXED in Firefox 40

Status

()

Core
DOM
RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: bz, Assigned: baku)

Tracking

Trunk
mozilla40
x86
Mac OS X
Points:
---
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(firefox40 fixed)

Details

(URL)

Attachments

(4 attachments, 4 obsolete attachments)

(Assignee)

Updated

3 years ago
Assignee: nobody → amarchesini
(Assignee)

Comment 1

3 years ago
Created attachment 8585574 [details] [diff] [review]
01_ref.patch

new WebSocket("ws://something/#") should fail.
Attachment #8585574 - Flags: review?(bugs)
(Assignee)

Comment 2

3 years ago
Created attachment 8585575 [details] [diff] [review]
02_url.patch

The default URL when the socket is not connected should be parsed.
Attachment #8585575 - Flags: review?(bugs)
(Assignee)

Comment 3

3 years ago
Created attachment 8585576 [details] [diff] [review]
03_port.patch

Security error if the port is not allowed.
Attachment #8585576 - Flags: review?(bugs)
Comment on attachment 8585574 [details] [diff] [review]
01_ref.patch

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

::: dom/base/WebSocket.cpp
@@ +1867,5 @@
>  
> +  bool hasRef;
> +  rv = parsedURL->GetHasRef(&hasRef);
> +  NS_ENSURE_SUCCESS(rv, NS_ERROR_DOM_SYNTAX_ERR);
> +  NS_ENSURE_TRUE(NS_SUCCEEDED(rv) && !hasRef,

Don't need to check rv twice
(Assignee)

Comment 5

3 years ago
Created attachment 8585620 [details] [diff] [review]
01_ref.patch
Attachment #8585574 - Attachment is obsolete: true
Attachment #8585574 - Flags: review?(bugs)
Attachment #8585620 - Flags: review?(bugs)

Updated

3 years ago
Attachment #8585575 - Flags: review?(bugs) → review+

Updated

3 years ago
Attachment #8585576 - Flags: review?(bugs) → review+

Updated

3 years ago
Attachment #8585620 - Flags: review?(bugs) → review+
(Assignee)

Comment 6

3 years ago
Created attachment 8585665 [details] [diff] [review]
patch 1
Attachment #8585620 - Attachment is obsolete: true
(Assignee)

Comment 7

3 years ago
Created attachment 8585666 [details] [diff] [review]
patch 2
Attachment #8585575 - Attachment is obsolete: true
(Assignee)

Comment 8

3 years ago
Created attachment 8585667 [details] [diff] [review]
patch 3
Attachment #8585576 - Attachment is obsolete: true
(Assignee)

Comment 9

3 years ago
Patches ready to land, if this is green enough:
https://treeherder.mozilla.org/#/jobs?repo=try&revision=ab658a9d577b
Keywords: checkin-needed
(Assignee)

Updated

3 years ago
Keywords: checkin-needed → leave-open
sorry had to back this out for test failures like https://treeherder.mozilla.org/logviewer.html#?job_id=8275103&repo=mozilla-inbound
Flags: needinfo?(amarchesini)
(Assignee)

Comment 13

3 years ago
Here the report about the webplatform tests:

/websockets/Close-reason-unpaired-surrogates.htm -> bigger problem about Unicode
/websockets/Close-undefined.htm -> The test is invalid - close(undefined) is OK
/websockets/Create-Secure-blocked-port.htm -> FIXED - patch 3
/websockets/Create-Secure-verify-url-set-non-default-port.htm -> the test has a JS error.
/websockets/constructor/002.html -> FIXED - patch 1
/websockets/constructor/010.html -> The test is invalid - webSocket protocol error
/websockets/constructor/018.html -> The test is invalid - no percentage replacement is required from the spec
/websockets/cookies/001.html -> Work-in-progress
/websockets/interfaces.html -> The test is invalid - no stringifier in the webidl definition
/websockets/interfaces/CloseEvent/historical.html -> No historical Close Event support
/websockets/interfaces/WebSocket/events/013.html -> This should be allowed by the spec.
/websockets/interfaces/WebSocket/readyState/003.html -> the test is invalid
/websockets/interfaces/WebSocket/url/001.html -> FIXED - patch 2
/websockets/opening-handshake/005.html -> The test is invalid - webSocket protocol error
/websockets/cookies/005.html -> The test is invalid - webSocket protocol error
/websockets/interfaces/WebSocket/close/close-connecting.html -> The test is invalid - webSocket not active
(Assignee)

Comment 14

3 years ago
Created attachment 8586090 [details] [diff] [review]
patch 4
Attachment #8586090 - Flags: review?(james)
Attachment #8586090 - Flags: review?(james) → review+
You need to log in before you can comment on or make changes to this bug.