mirror of
https://github.com/servo/servo.git
synced 2025-08-10 07:55:33 +01:00
Add start_time to resource timing.
This commit is contained in:
parent
1f64024655
commit
fcad88cddd
8 changed files with 280 additions and 15 deletions
|
@ -19634,7 +19634,7 @@
|
|||
"testharness"
|
||||
],
|
||||
"mozilla/window_performance.html": [
|
||||
"690870b7080e179481ca0255f7c30337e8b6636a",
|
||||
"302073e8041763102d678326509d7ef0a1fb5c79",
|
||||
"testharness"
|
||||
],
|
||||
"mozilla/window_performance_topLevelDomComplete.html": [
|
||||
|
|
|
@ -1,4 +0,0 @@
|
|||
[window_performance.html]
|
||||
[window_performance]
|
||||
expected: FAIL
|
||||
|
|
@ -16,8 +16,13 @@ test(function() {
|
|||
assert_not_equals(entries.length, 0);
|
||||
assert_true(entries[0] instanceof PerformanceNavigationTiming);
|
||||
|
||||
// TODO(#21254) navigationTiming/startTime is not fully implemented yet, so this assertion will fail
|
||||
assert_greater_than(entries[0].startTime, 0);
|
||||
/* PerformanceResourceTiming */
|
||||
var resourceEntries = window.performance.getEntriesByType("resource");
|
||||
assert_not_equals(resourceEntries.length, 0);
|
||||
assert_true(resourceEntries[0] instanceof PerformanceResourceTiming);
|
||||
// no redirects => 0 < startTime == fetchStart
|
||||
assert_greater_than(resourceEntries[0].startTime, 0);
|
||||
assert_equals(resourceEntries[0].startTime, resourceEntries[0].fetchStart);
|
||||
|
||||
var last = window.performance.now();
|
||||
assert_greater_than(last, 0);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue