Implement EventSource and update test expectations

This commit is contained in:
Keith Yeung 2015-12-12 22:06:21 -08:00
parent e3dd36f0f3
commit 1d62db405e
58 changed files with 543 additions and 51 deletions

View file

@ -9,6 +9,8 @@ skip: true
skip: false
[DOMEvents]
skip: false
[eventsource]
skip: false
[FileAPI]
skip: false
[html]

View file

@ -0,0 +1,6 @@
[eventsource-close.htm]
type: testharness
expected: TIMEOUT
[dedicated worker - EventSource: close()]
expected: TIMEOUT

View file

@ -0,0 +1,20 @@
[eventsource-constructor-non-same-origin.htm]
type: testharness
[dedicated worker - EventSource: constructor (act as if there is a network error) (http://example.not/)]
expected: TIMEOUT
[dedicated worker - EventSource: constructor (act as if there is a network error) (https://example.not/test)]
expected: TIMEOUT
[dedicated worker - EventSource: constructor (act as if there is a network error) (ftp://example.not/)]
expected: TIMEOUT
[dedicated worker - EventSource: constructor (act as if there is a network error) (about:blank)]
expected: TIMEOUT
[dedicated worker - EventSource: constructor (act as if there is a network error) (mailto:whatwg@awesome.example)]
expected: TIMEOUT
[dedicated worker - EventSource: constructor (act as if there is a network error) (javascript:alert('FAIL'))]
expected: TIMEOUT

View file

@ -0,0 +1,5 @@
[eventsource-eventtarget.htm]
type: testharness
[dedicated worker - EventSource: addEventListener()]
expected: FAIL

View file

@ -0,0 +1,6 @@
[eventsource-onmesage.htm]
type: testharness
expected: TIMEOUT
[dedicated worker - EventSource: onmessage]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[eventsource-onopen.htm]
type: testharness
expected: TIMEOUT
[dedicated worker - EventSource: onopen (announcing the connection)]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[event-data.html]
type: testharness
expected: TIMEOUT
[EventSource: lines and data parsing]
expected: TIMEOUT

View file

@ -0,0 +1,9 @@
[eventsource-close.htm]
type: testharness
expected: TIMEOUT
[EventSource: close()]
expected: TIMEOUT
[EventSource: close(), test events]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[eventsource-constructor-document-domain.htm]
type: testharness
expected: TIMEOUT
[EventSource: document.domain]
expected: TIMEOUT

View file

@ -0,0 +1,20 @@
[eventsource-constructor-non-same-origin.htm]
type: testharness
[EventSource: constructor (act as if there is a network error) (http://example.not/)]
expected: TIMEOUT
[EventSource: constructor (act as if there is a network error) (https://example.not/test)]
expected: TIMEOUT
[EventSource: constructor (act as if there is a network error) (ftp://example.not/)]
expected: TIMEOUT
[EventSource: constructor (act as if there is a network error) (about:blank)]
expected: TIMEOUT
[EventSource: constructor (act as if there is a network error) (mailto:whatwg@awesome.example)]
expected: TIMEOUT
[EventSource: constructor (act as if there is a network error) (javascript:alert('FAIL'))]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[eventsource-constructor-stringify.htm]
type: testharness
expected: TIMEOUT
[EventSource: stringify argument, object]
expected: TIMEOUT

View file

@ -0,0 +1,5 @@
[eventsource-constructor-url-multi-window.htm]
type: testharness
[EventSource: resolving URLs]
expected: FAIL

View file

@ -0,0 +1,21 @@
[eventsource-cross-origin.htm]
type: testharness
expected: TIMEOUT
[EventSource: cross-origin basic use]
expected: TIMEOUT
[EventSource: cross-origin redirect use]
expected: TIMEOUT
[EventSource: cross-origin redirect use recon]
expected: TIMEOUT
[EventSource: cross-origin allow-origin: http://example.org should fail]
expected: TIMEOUT
[EventSource: cross-origin allow-origin:'' should fail]
expected: TIMEOUT
[EventSource: cross-origin No allow-origin should fail]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[eventsource-eventtarget.htm]
type: testharness
expected: TIMEOUT
[EventSource: addEventListener()]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[eventsource-onmessage.htm]
type: testharness
expected: TIMEOUT
[EventSource: onmessage]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[eventsource-onopen.htm]
type: testharness
expected: TIMEOUT
[EventSource: onopen (announcing the connection)]
expected: TIMEOUT

View file

@ -0,0 +1,9 @@
[eventsource-reconnect.htm]
type: testharness
expected: TIMEOUT
[EventSource: reconnection 200]
expected: TIMEOUT
[EventSource: reconnection, test reconnection events]
expected: TIMEOUT

View file

@ -0,0 +1,5 @@
[eventsource-request-cancellation.htm]
type: testharness
[EventSource: request cancellation]
expected: FAIL

View file

@ -0,0 +1,6 @@
[format-bom-2.htm]
type: testharness
expected: TIMEOUT
[EventSource: Double BOM]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-bom.htm]
type: testharness
expected: TIMEOUT
[EventSource: BOM]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-comments.htm]
type: testharness
expected: TIMEOUT
[EventSource: comment fest]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-data-before-final-empty-line.htm]
type: testharness
expected: TIMEOUT
[EventSource: a data before final empty line]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-field-data.htm]
type: testharness
expected: TIMEOUT
[EventSource: data field parsing]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-field-event-empty.htm]
type: testharness
expected: TIMEOUT
[EventSource: empty "event" field]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-field-event.htm]
type: testharness
expected: TIMEOUT
[EventSource: custom event name]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-field-id-2.htm]
type: testharness
expected: TIMEOUT
[EventSource: Last-Event-ID (2)]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-field-id.htm]
type: testharness
expected: TIMEOUT
[EventSource: Last-Event-ID]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-field-parsing.htm]
type: testharness
expected: TIMEOUT
[EventSource: field parsing]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-field-retry-bogus.htm]
type: testharness
expected: TIMEOUT
[EventSource: "retry" field (bogus)]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-field-retry-empty.htm]
type: testharness
expected: TIMEOUT
[EventSource: empty retry field]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-field-retry.htm]
type: testharness
expected: TIMEOUT
[EventSource: "retry" field]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-field-unknown.htm]
type: testharness
expected: TIMEOUT
[EventSource: unknown fields and parsing fun]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-leading-space.htm]
type: testharness
expected: TIMEOUT
[EventSource: leading space]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-mime-bogus.htm]
type: testharness
expected: TIMEOUT
[EventSource: bogus MIME type]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-mime-trailing-semicolon.htm]
type: testharness
expected: TIMEOUT
[EventSource: MIME type with trailing ;]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-mime-valid-bogus.htm]
type: testharness
expected: TIMEOUT
[EventSource: incorrect valid MIME type]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-newlines.htm]
type: testharness
expected: TIMEOUT
[EventSource: newline fest]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-null-character.html]
type: testharness
expected: TIMEOUT
[EventSource: null character in response]
expected: TIMEOUT

View file

@ -0,0 +1,6 @@
[format-utf-8.htm]
type: testharness
expected: TIMEOUT
[EventSource: always UTF-8]
expected: TIMEOUT

View file

@ -0,0 +1,11 @@
[interfaces.html]
type: testharness
[EventSource interface: existence and properties of interface object]
expected: FAIL
[EventSource interface: existence and properties of interface prototype object]
expected: FAIL
[Stringification of new EventSource("http://foo")]
expected: FAIL

View file

@ -0,0 +1,6 @@
[request-accept.htm]
type: testharness
expected: TIMEOUT
[EventSource: Accept header]
expected: TIMEOUT

View file

@ -0,0 +1,9 @@
[request-cache-control.htm]
type: testharness
expected: TIMEOUT
[EventSource: Cache-Control]
expected: TIMEOUT
[EventSource: Cache-Control 1]
expected: TIMEOUT

View file

@ -0,0 +1,12 @@
[request-credentials.htm]
type: testharness
expected: TIMEOUT
[EventSource: credentials: credentials enabled]
expected: TIMEOUT
[EventSource: credentials: credentials disabled]
expected: TIMEOUT
[EventSource: credentials: credentials default]
expected: TIMEOUT

View file

@ -0,0 +1,15 @@
[request-redirect.htm]
type: testharness
expected: TIMEOUT
[EventSource: redirect (301)]
expected: TIMEOUT
[EventSource: redirect (302)]
expected: TIMEOUT
[EventSource: redirect (303)]
expected: TIMEOUT
[EventSource: redirect (307)]
expected: TIMEOUT

View file

@ -0,0 +1,24 @@
[request-status-error.htm]
type: testharness
expected: TIMEOUT
[EventSource: incorrect HTTP status code (204)]
expected: TIMEOUT
[EventSource: incorrect HTTP status code (205)]
expected: TIMEOUT
[EventSource: incorrect HTTP status code (210)]
expected: TIMEOUT
[EventSource: incorrect HTTP status code (299)]
expected: TIMEOUT
[EventSource: incorrect HTTP status code (404)]
expected: TIMEOUT
[EventSource: incorrect HTTP status code (410)]
expected: TIMEOUT
[EventSource: incorrect HTTP status code (503)]
expected: TIMEOUT

View file

@ -0,0 +1,5 @@
[eventsource-close.htm]
type: testharness
[shared worker - EventSource: close()]
expected: FAIL

View file

@ -0,0 +1,20 @@
[eventsource-constructor-non-same-origin.htm]
type: testharness
[shared worker - EventSource: constructor (act as if there is a network error) (http://example.not)]
expected: FAIL
[shared worker - EventSource: constructor (act as if there is a network error) (https://example.not/test)]
expected: FAIL
[shared worker - EventSource: constructor (act as if there is a network error) (ftp://example.not)]
expected: FAIL
[shared worker - EventSource: constructor (act as if there is a network error) (about:blank)]
expected: FAIL
[shared worker - EventSource: constructor (act as if there is a network error) (mailto:whatwg@awesome.example)]
expected: FAIL
[shared worker - EventSource: constructor (act as if there is a network error) (javascript:alert('FAIL'))]
expected: FAIL

View file

@ -0,0 +1,5 @@
[eventsource-constructor-url-bogus.htm]
type: testharness
[shared worker - EventSource: constructor (invalid URL)]
expected: FAIL

View file

@ -0,0 +1,5 @@
[eventsource-eventtarget.htm]
type: testharness
[shared worker - EventSource: addEventListener()]
expected: FAIL

View file

@ -0,0 +1,5 @@
[eventsource-onmesage.htm]
type: testharness
[shared worker - EventSource: onmessage]
expected: FAIL

View file

@ -0,0 +1,5 @@
[eventsource-onopen.htm]
type: testharness
[shared worker - EventSource: onopen (announcing the connection)]
expected: FAIL

View file

@ -0,0 +1,5 @@
[eventsource-prototype.htm]
type: testharness
[shared worker - EventSource: prototype et al]
expected: FAIL

View file

@ -0,0 +1,5 @@
[eventsource-url.htm]
type: testharness
[shared worker - EventSource: url]
expected: FAIL

View file

@ -7755,54 +7755,6 @@
[EventSource interface: existence and properties of interface object]
expected: FAIL
[EventSource interface object length]
expected: FAIL
[EventSource interface: existence and properties of interface prototype object]
expected: FAIL
[EventSource interface: existence and properties of interface prototype object's "constructor" property]
expected: FAIL
[EventSource interface: attribute url]
expected: FAIL
[EventSource interface: attribute withCredentials]
expected: FAIL
[EventSource interface: constant CONNECTING on interface object]
expected: FAIL
[EventSource interface: constant CONNECTING on interface prototype object]
expected: FAIL
[EventSource interface: constant OPEN on interface object]
expected: FAIL
[EventSource interface: constant OPEN on interface prototype object]
expected: FAIL
[EventSource interface: constant CLOSED on interface object]
expected: FAIL
[EventSource interface: constant CLOSED on interface prototype object]
expected: FAIL
[EventSource interface: attribute readyState]
expected: FAIL
[EventSource interface: attribute onopen]
expected: FAIL
[EventSource interface: attribute onmessage]
expected: FAIL
[EventSource interface: attribute onerror]
expected: FAIL
[EventSource interface: operation close()]
expected: FAIL
[WebSocket interface: existence and properties of interface object]
expected: FAIL
@ -9429,9 +9381,6 @@
[ImageBitmap interface object name]
expected: FAIL
[EventSource interface object name]
expected: FAIL
[MessageChannel interface object name]
expected: FAIL

View file

@ -99,6 +99,7 @@ var interfaceNamesInGlobalScope = [
"Element",
"ErrorEvent",
"Event",
"EventSource",
"EventTarget",
"File",
"FileList",