summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/workers/Worker-constructor-proto.any.js
blob: 297fe6c58b47af6ff4ee206b8268f439b4c09f4b (plain)
1
2
3
4
5
6
7
//META: global=worker
test(() => {
  const proto = {};
  assert_equals(String(Object.getPrototypeOf(WorkerLocation)).replace(/\n/g, " ").replace(/\s\s+/g, " "), "function () { [native code] }");
  Object.setPrototypeOf(WorkerLocation, proto);
  assert_equals(Object.getPrototypeOf(WorkerLocation), proto);
}, 'Tests that setting the proto of a built in constructor is not reset.');