Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /timing-entrytypes-registry/registry.any.html - WPT Dashboard Interop Dashboard
- /timing-entrytypes-registry/registry.any.worker.html - WPT Dashboard Interop Dashboard
// META: script=resources/utils.js
test(() => {
assert_true(!!self.PerformanceObserver, "PerformanceObserver");
assert_true(!!self.PerformanceObserver.supportedEntryTypes,
"PerformanceObserver.supportedEntryTypes");
}, "PerformanceObserver.supportedEntryTypes exists");
// UPDATE HERE if new entry
[
[ "mark", "PerformanceMark" ],
[ "measure", "PerformanceMeasure" ],
[ "resource", "PerformanceResourceTiming" ],
].forEach(test_support);
// UPDATE BELOW to ensure the entry gets created
// mark
self.performance.mark('mymark');
// measure
self.performance.measure('mymeasure');
// resource
fetch(self.location.href + "?" + Math.random());