зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1468849 [wpt PR 9831] - Update the server-timing IDL file, a=testonly
Automatic update from web-platform-testsUpdate the server-timing IDL file (#9831) -- wpt-commits: 55c9a7759521a1aece42d3dea4891db96ef0d223 wpt-pr: 9831
This commit is contained in:
Родитель
07f1343052
Коммит
49c6aedcc1
|
@ -288660,6 +288660,11 @@
|
|||
{}
|
||||
]
|
||||
],
|
||||
"interfaces/resource-timing.idl": [
|
||||
[
|
||||
{}
|
||||
]
|
||||
],
|
||||
"interfaces/screen-orientation.idl": [
|
||||
[
|
||||
{}
|
||||
|
@ -288675,6 +288680,11 @@
|
|||
{}
|
||||
]
|
||||
],
|
||||
"interfaces/server-timing.idl": [
|
||||
[
|
||||
{}
|
||||
]
|
||||
],
|
||||
"interfaces/storage.idl": [
|
||||
[
|
||||
{}
|
||||
|
@ -372920,9 +372930,13 @@
|
|||
{}
|
||||
]
|
||||
],
|
||||
"resource-timing/idlharness.html": [
|
||||
"resource-timing/idlharness.any.js": [
|
||||
[
|
||||
"/resource-timing/idlharness.html",
|
||||
"/resource-timing/idlharness.any.html",
|
||||
{}
|
||||
],
|
||||
[
|
||||
"/resource-timing/idlharness.any.worker.html",
|
||||
{}
|
||||
]
|
||||
],
|
||||
|
@ -373496,6 +373510,16 @@
|
|||
{}
|
||||
]
|
||||
],
|
||||
"server-timing/idlharness.any.js": [
|
||||
[
|
||||
"/server-timing/idlharness.any.html",
|
||||
{}
|
||||
],
|
||||
[
|
||||
"/server-timing/idlharness.any.worker.html",
|
||||
{}
|
||||
]
|
||||
],
|
||||
"server-timing/navigation_timing_idl.html": [
|
||||
[
|
||||
"/server-timing/navigation_timing_idl.html",
|
||||
|
@ -589681,6 +589705,10 @@
|
|||
"9ddb3a7bfce2454a3f7d835785db912f70521449",
|
||||
"support"
|
||||
],
|
||||
"interfaces/resource-timing.idl": [
|
||||
"75fcdf5c6ac811254e1a025cd58d958f27ab5b5b",
|
||||
"support"
|
||||
],
|
||||
"interfaces/screen-orientation.idl": [
|
||||
"ace5a4ae79933cdfd7ecf5c3801e93f0636fe57b",
|
||||
"support"
|
||||
|
@ -589693,6 +589721,10 @@
|
|||
"3b2cb524838f2274463664621fddc7c927ac95af",
|
||||
"support"
|
||||
],
|
||||
"interfaces/server-timing.idl": [
|
||||
"0c9862d6e00d02a0955a1eaf2ec4f237bd060ac4",
|
||||
"support"
|
||||
],
|
||||
"interfaces/storage.idl": [
|
||||
"a1ad440d60e04902f494ecaced1fceb8560adc5c",
|
||||
"support"
|
||||
|
@ -608961,8 +608993,8 @@
|
|||
"5e86b6a422cfa2815038aedff6a80ea2daecc238",
|
||||
"testharness"
|
||||
],
|
||||
"resource-timing/idlharness.html": [
|
||||
"f6ff9054d4412a6089ff182c9df0dcf4626dab21",
|
||||
"resource-timing/idlharness.any.js": [
|
||||
"a1bb5ee0f67683b42035fa683e9a984b0cf4d5dc",
|
||||
"testharness"
|
||||
],
|
||||
"resource-timing/iframe-setdomain.sub.html": [
|
||||
|
@ -609557,6 +609589,10 @@
|
|||
"e20e60bef34167b4608a837d0ddb311effa20773",
|
||||
"testharness"
|
||||
],
|
||||
"server-timing/idlharness.any.js": [
|
||||
"c59c42333012738d6f912c4fd0b01505be81504c",
|
||||
"testharness"
|
||||
],
|
||||
"server-timing/navigation_timing_idl.html": [
|
||||
"191f42a92f0ac135de816275920e54fa50065b15",
|
||||
"testharness"
|
||||
|
|
|
@ -0,0 +1,31 @@
|
|||
// GENERATED CONTENT - DO NOT EDIT
|
||||
// Content of this file was automatically extracted from the
|
||||
// "Resource Timing Level 2" spec.
|
||||
// See: https://w3c.github.io/resource-timing/
|
||||
|
||||
[Exposed=(Window,Worker)]
|
||||
interface PerformanceResourceTiming : PerformanceEntry {
|
||||
readonly attribute DOMString initiatorType;
|
||||
readonly attribute DOMString nextHopProtocol;
|
||||
readonly attribute DOMHighResTimeStamp workerStart;
|
||||
readonly attribute DOMHighResTimeStamp redirectStart;
|
||||
readonly attribute DOMHighResTimeStamp redirectEnd;
|
||||
readonly attribute DOMHighResTimeStamp fetchStart;
|
||||
readonly attribute DOMHighResTimeStamp domainLookupStart;
|
||||
readonly attribute DOMHighResTimeStamp domainLookupEnd;
|
||||
readonly attribute DOMHighResTimeStamp connectStart;
|
||||
readonly attribute DOMHighResTimeStamp connectEnd;
|
||||
readonly attribute DOMHighResTimeStamp secureConnectionStart;
|
||||
readonly attribute DOMHighResTimeStamp requestStart;
|
||||
readonly attribute DOMHighResTimeStamp responseStart;
|
||||
readonly attribute DOMHighResTimeStamp responseEnd;
|
||||
readonly attribute unsigned long long transferSize;
|
||||
readonly attribute unsigned long long encodedBodySize;
|
||||
readonly attribute unsigned long long decodedBodySize;
|
||||
[Default] object toJSON();
|
||||
};
|
||||
partial interface Performance {
|
||||
void clearResourceTimings();
|
||||
void setResourceTimingBufferSize(unsigned long maxSize);
|
||||
attribute EventHandler onresourcetimingbufferfull;
|
||||
};
|
|
@ -0,0 +1,16 @@
|
|||
// GENERATED CONTENT - DO NOT EDIT
|
||||
// Content of this file was automatically extracted from the
|
||||
// "Server Timing" spec.
|
||||
// See: https://w3c.github.io/server-timing/
|
||||
|
||||
[Exposed=(Window,Worker)]
|
||||
interface PerformanceServerTiming {
|
||||
readonly attribute DOMString name;
|
||||
readonly attribute DOMHighResTimeStamp duration;
|
||||
readonly attribute DOMString description;
|
||||
[Default] object toJSON();
|
||||
};
|
||||
[Exposed=(Window,Worker)]
|
||||
partial interface PerformanceResourceTiming {
|
||||
readonly attribute FrozenArray<PerformanceServerTiming> serverTiming;
|
||||
};
|
|
@ -0,0 +1,28 @@
|
|||
// META: script=/resources/WebIDLParser.js
|
||||
// META: script=/resources/idlharness.js
|
||||
|
||||
'use strict';
|
||||
|
||||
// https://w3c.github.io/resource-timing/
|
||||
|
||||
promise_test(async () => {
|
||||
const [idl, perf, hrtime, dom, html] = await Promise.all([
|
||||
'/interfaces/resource-timing.idl',
|
||||
'/interfaces/performance-timeline.idl',
|
||||
'/interfaces/hr-time.idl',
|
||||
'/interfaces/dom.idl',
|
||||
'/interfaces/html.idl',
|
||||
].map(url => fetch(url).then(r => r.text())));
|
||||
|
||||
const idl_array = new IdlArray();
|
||||
idl_array.add_idls(idl);
|
||||
idl_array.add_dependency_idls(perf);
|
||||
idl_array.add_dependency_idls(hrtime);
|
||||
idl_array.add_dependency_idls(dom);
|
||||
idl_array.add_dependency_idls(html);
|
||||
idl_array.add_objects({
|
||||
Performance: ['performance'],
|
||||
PerformanceResourceTiming: ["performance.getEntriesByType('resource')[0]"]
|
||||
});
|
||||
idl_array.test();
|
||||
}, 'Test server-timing IDL implementation');
|
|
@ -1,97 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Resource Timing IDL tests</title>
|
||||
<link rel="author" title="W3C" href="http://www.w3.org/" />
|
||||
<link rel="help" href="https://w3c.github.io/resource-timing/"/>
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/resources/WebIDLParser.js"></script>
|
||||
<script src="/resources/idlharness.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Resource Timing IDL tests</h1>
|
||||
<div id="log"></div>
|
||||
|
||||
<pre id='untested_idl' style='display:none'>
|
||||
|
||||
interface Window {
|
||||
};
|
||||
|
||||
interface Performance {
|
||||
};
|
||||
|
||||
interface PerformanceEntry {
|
||||
readonly attribute DOMString name;
|
||||
readonly attribute DOMString entryType;
|
||||
readonly attribute DOMHighResTimeStamp startTime;
|
||||
readonly attribute DOMHighResTimeStamp duration;
|
||||
[Default] object toJSON();
|
||||
};
|
||||
|
||||
[Exposed=(Window,Worker)]
|
||||
interface EventHandler {
|
||||
};
|
||||
|
||||
typedef double DOMHighResTimeStamp;
|
||||
|
||||
[Exposed=(Window,Worker)]
|
||||
partial interface Performance {
|
||||
PerformanceEntryList getEntries();
|
||||
PerformanceEntryList getEntriesByType(DOMString entryType);
|
||||
PerformanceEntryList getEntriesByName(DOMString name, optional DOMString entryType);
|
||||
};
|
||||
|
||||
partial interface Window {
|
||||
[Replaceable] readonly attribute Performance performance;
|
||||
};
|
||||
</pre>
|
||||
|
||||
<pre id='idl'>
|
||||
[Exposed=(Window,Worker)]
|
||||
interface PerformanceResourceTiming : PerformanceEntry {
|
||||
readonly attribute DOMString initiatorType;
|
||||
readonly attribute DOMString nextHopProtocol;
|
||||
readonly attribute DOMHighResTimeStamp workerStart;
|
||||
readonly attribute DOMHighResTimeStamp redirectStart;
|
||||
readonly attribute DOMHighResTimeStamp redirectEnd;
|
||||
readonly attribute DOMHighResTimeStamp fetchStart;
|
||||
readonly attribute DOMHighResTimeStamp domainLookupStart;
|
||||
readonly attribute DOMHighResTimeStamp domainLookupEnd;
|
||||
readonly attribute DOMHighResTimeStamp connectStart;
|
||||
readonly attribute DOMHighResTimeStamp connectEnd;
|
||||
readonly attribute DOMHighResTimeStamp secureConnectionStart;
|
||||
readonly attribute DOMHighResTimeStamp requestStart;
|
||||
readonly attribute DOMHighResTimeStamp responseStart;
|
||||
readonly attribute DOMHighResTimeStamp responseEnd;
|
||||
readonly attribute unsigned long long transferSize;
|
||||
readonly attribute unsigned long long encodedBodySize;
|
||||
readonly attribute unsigned long long decodedBodySize;
|
||||
[Default] object toJSON();
|
||||
};
|
||||
|
||||
partial interface Performance {
|
||||
void clearResourceTimings();
|
||||
void setResourceTimingBufferSize(unsigned long maxSize);
|
||||
attribute EventHandler onresourcetimingbufferfull;
|
||||
};
|
||||
</pre>
|
||||
|
||||
<script>
|
||||
|
||||
(function () {
|
||||
var idl_array = new IdlArray();
|
||||
|
||||
idl_array.add_untested_idls(document.getElementById("untested_idl").textContent);
|
||||
idl_array.add_idls(document.getElementById("idl").textContent);
|
||||
|
||||
idl_array.add_objects({Performance: ['window.performance'],
|
||||
PerformanceResourceTiming: ["window.performance.getEntriesByType('resource')[0]"]});
|
||||
|
||||
idl_array.test();
|
||||
})();
|
||||
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,21 @@
|
|||
// META: script=/resources/WebIDLParser.js
|
||||
// META: script=/resources/idlharness.js
|
||||
|
||||
'use strict';
|
||||
|
||||
// https://w3c.github.io/server-timing/
|
||||
|
||||
promise_test(async () => {
|
||||
const idl = await fetch('/interfaces/server-timing.idl').then(r => r.text());
|
||||
const res = await fetch('/interfaces/resource-timing.idl').then(r => r.text());
|
||||
const perf = await fetch('/interfaces/performance-timeline.idl').then(r => r.text());
|
||||
|
||||
const idl_array = new IdlArray();
|
||||
idl_array.add_idls(idl);
|
||||
idl_array.add_dependency_idls(res);
|
||||
idl_array.add_dependency_idls(perf);
|
||||
idl_array.add_objects({
|
||||
Performance: ['performance'],
|
||||
});
|
||||
idl_array.test();
|
||||
}, 'Test server-timing IDL implementation');
|
Загрузка…
Ссылка в новой задаче