• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1importScripts("/resources/testharness.js");
2importScripts("resources/webperftestharness.js");
3
4function emit_test(attrName) {
5    test(function() {
6      performance.mark(attrName);
7      performance.clearMarks(attrName);
8    }, "performance.mark should not throw if used with timing attribute " + attrName
9       + " in workers");
10}
11for (var i in timingAttributes) {
12  emit_test(timingAttributes[i]);
13}
14
15function emit_test2(attrName) {
16    test(function() {
17      performance.measure(attrName);
18      performance.clearMeasures(attrName);
19    }, "performance.measure should not throw if used with timing attribute " + attrName
20       + " in workers");
21}
22for (var i in timingAttributes) {
23  emit_test2(timingAttributes[i]);
24}
25done();
26