On Fri, 20 Sep 2013 13:20:44 +0200, Hallvord Steen <[email protected]>
wrote:
Test case
http://w3c-test.org/web-platform-tests/master/XMLHttpRequest/send-redirect-bogus.htm
has an interesting behaviour in Gecko. Last test fails with output:
assert_equals: expected "" but got "WEBSRT MARKETING"
Test returns a bogus redirect like
HTTP/1.1 303 WEBSRT MARKETING
Location: foobar:[email protected]
Per spec, this is a network error. Now, the spec does *not* explicitly
say that exposing .statusText for network errors is wrong, although the
test asserts that it is. Maybe some spec clarification is required? Or
maybe it makes sense to pass status and statusText on to the script even
if redirects fail, and we should spec that?
-Hallvord
http://xhr.spec.whatwg.org/#network-error
->
http://xhr.spec.whatwg.org/#request-error
->
http://xhr.spec.whatwg.org/#terminate-the-request
->
"Set the error flag."
http://xhr.spec.whatwg.org/#dom-xmlhttprequest-statustext
->
"If the error flag is set, return the empty string."
(I'm not sure where the spec says that the above case is a network error,
though.)
--
Simon Pieters
Opera Software