summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/workers/interfaces.worker.js
blob: f07669ba71c5bae3d6b29e909ae55d64afa4275f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
"use strict";

importScripts("/resources/testharness.js");
importScripts("/resources/WebIDLParser.js", "/resources/idlharness.js");

var request = new XMLHttpRequest();
request.onload = function() {
  var idlArray = new IdlArray();
  var idls = request.responseText;
  idlArray.add_idls(idls);
  idlArray.add_objects({
    DedicatedWorkerGlobalScope: ['self'],
    WorkerNavigator: ['self.navigator'],
    WorkerLocation: ['self.location'],
  });
  idlArray.test();
  done();
};
request.open("GET", "interfaces.idl");
request.send();