WorkerGlobalScope's self, location and navigator attributes should not be replaceable
authorcdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 3 May 2016 15:50:37 +0000 (15:50 +0000)
committercdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 3 May 2016 15:50:37 +0000 (15:50 +0000)
commit0d9027ffdb8818f5944ed2c738d311662d075650
tree5413682eebd5f93bfe7d260c14ccb396e9b03115
parent2d31690055b3ce9760a9e4015f398b5d4a44392d
WorkerGlobalScope's self, location and navigator attributes should not be replaceable
https://bugs.webkit.org/show_bug.cgi?id=157296
<rdar://problem/25962738>

Patch by Pranjal Jumde <pjumde@apple.com> on 2016-05-03
Reviewed by Chris Dumez.

Source/WebCore:

Tests: http/tests/workers/location-readonly.html
       http/tests/workers/navigator-readonly.html
       http/tests/workers/self-readonly.html

* workers/WorkerGlobalScope.idl:
The 'self', 'location', and 'navigator' properties of the WorkerGlobalScope must be immutable.
See: https://html.spec.whatwg.org/multipage/workers.html#the-workerglobalscope-common-interface

LayoutTests:

* http/tests/workers/location-readonly-expected.txt: Added.
* http/tests/workers/location-readonly.html: Added.
* http/tests/workers/navigator-readonly-expected.txt: Added.
* http/tests/workers/navigator-readonly.html: Added.
* http/tests/workers/self-readonly-expected.txt: Added.
* http/tests/workers/self-readonly.html: Added.
* http/tests/workers/worker-location.js: Added.
* http/tests/workers/worker-navigator.js: Added.
* http/tests/workers/worker-self.js: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@200375 268f45cc-cd09-0410-ab3c-d52691b4dbfc
12 files changed:
LayoutTests/ChangeLog
LayoutTests/http/tests/workers/location-readonly-expected.txt [new file with mode: 0644]
LayoutTests/http/tests/workers/location-readonly.html [new file with mode: 0644]
LayoutTests/http/tests/workers/navigator-readonly-expected.txt [new file with mode: 0644]
LayoutTests/http/tests/workers/navigator-readonly.html [new file with mode: 0644]
LayoutTests/http/tests/workers/self-readonly-expected.txt [new file with mode: 0644]
LayoutTests/http/tests/workers/self-readonly.html [new file with mode: 0644]
LayoutTests/http/tests/workers/worker-location.js [new file with mode: 0644]
LayoutTests/http/tests/workers/worker-navigator.js [new file with mode: 0644]
LayoutTests/http/tests/workers/worker-self.js [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/workers/WorkerGlobalScope.idl