| Index: third_party/WebKit/LayoutTests/http/tests/security/cookies/websocket/resources/set-cookie.html
|
| diff --git a/third_party/WebKit/LayoutTests/http/tests/security/cookies/websocket/resources/set-cookie.html b/third_party/WebKit/LayoutTests/http/tests/security/cookies/websocket/resources/set-cookie.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..a0a59c11773ad942d5fd6c04dd725a36743ea444
|
| --- /dev/null
|
| +++ b/third_party/WebKit/LayoutTests/http/tests/security/cookies/websocket/resources/set-cookie.html
|
| @@ -0,0 +1,31 @@
|
| +<!DOCTYPE html>
|
| +<script src="/websocket/resources/get-request-header.js"></script>
|
| +<script src="/websocket/resources/cookie-test-util.js"></script>
|
| +<script>
|
| +function notifySuccess(value) {
|
| + window.parent.postMessage('DONE: ' + value, '*');
|
| +}
|
| +
|
| +function notifyFailure(reason) {
|
| + window.parent.postMessage('FAIL: ' + reason, '*');
|
| +}
|
| +
|
| +let origin = WS_ORIGIN;
|
| +if (location.search == '?remote') {
|
| + origin = WS_REMOTE_ORIGIN;
|
| +}
|
| +
|
| +setCookie(origin).then(
|
| + () => connectAndGetRequestHeadersFrom(origin),
|
| + notifyFailure
|
| +).then(
|
| + headers => {
|
| + const cookie = headers['cookie'];
|
| + return clear(origin).then(() => {
|
| + notifySuccess(JSON.stringify(cookie));
|
| + });
|
| + }
|
| +).catch(
|
| + notifyFailure
|
| +);
|
| +</script>
|
|
|