Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(269)

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/serviceworker/resources/immutable-prototype-serviceworker.js

Issue 2933913002: Upstream service worker prototype test to WPT
Patch Set: Migrate test for immutable prototype Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/serviceworker/immutable-prototype-serviceworker.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 function prototypeChain(global) {
2 let result = [];
3 while (global !== null) {
4 let thrown = false;
5 let next = global.__proto__;
6 try {
7 global.__proto__ = {};
8 result.push('mutable');
9 } catch (e) {
10 result.push('immutable');
11 }
12 global = next;
13 }
14 return result;
15 }
16
17 self.onmessage = function(e) {
18 e.data.postMessage(prototypeChain(self));
19 };
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/serviceworker/immutable-prototype-serviceworker.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698