summaryrefslogtreecommitdiff
path: root/dom/workers/test/WorkerDebuggerGlobalScope.setImmediate_debugger.js
blob: b5075c70fe3bf515ffb78a1f2f659fd595fe0874 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
"use strict";

this.onmessage = function (event) {
  switch (event.data) {
  case "ping":
    setImmediate(function () {
      postMessage("pong1");
    });
    postMessage("pong2");
    break;
  }
};