Index: third_party/WebKit/LayoutTests/external/wpt/server-timing/test_server_timing.html |
diff --git a/third_party/WebKit/LayoutTests/external/wpt/server-timing/test_server_timing.html b/third_party/WebKit/LayoutTests/external/wpt/server-timing/test_server_timing.html |
index 2a6ffa264999e9b9b151c4f133e55739f688dc93..43164d69221cadb40f067bbea8dccbd52d9b3931 100644 |
--- a/third_party/WebKit/LayoutTests/external/wpt/server-timing/test_server_timing.html |
+++ b/third_party/WebKit/LayoutTests/external/wpt/server-timing/test_server_timing.html |
@@ -10,35 +10,27 @@ |
window.addEventListener('load', function() { |
// there should be exactly two server-timing entries, 1 for document, 1 for img#one |
- test_entries(performance.getEntriesByType('server'), [{ |
- name: document.location.href, |
- entryType: 'server', |
- startTime: 0, |
- duration: 1.2, |
+ test_entries(performance.getEntriesByType('navigation')[0].serverTiming, [{ |
+ value: 1.2, |
metric: 'metric1', |
description: 'document', |
- }, { |
- name: document.querySelector('img#one').src, |
- entryType: 'server', |
- startTime: 0, |
- duration: 3.4, |
+ }]) |
+ test_entries(performance.getEntriesByName(document.querySelector('img#one').src)[0].serverTiming, [{ |
+ value: 3.4, |
metric: 'metric2', |
description: 'blue.png', |
}]) |
new PerformanceObserver(function(entryList, observer) { |
// there should be exactly one server-timing entry, 1 for img#two |
- test_entries(entryList.getEntriesByType('server'), [{ |
- name: document.querySelector('img#two').src, |
- entryType: 'server', |
- startTime: 0, |
- duration: 5.6, |
+ test_entries(entryList.getEntriesByName(document.querySelector('img#two').src)[0].serverTiming, [{ |
+ value: 5.6, |
metric: 'metric3', |
description: 'green.png', |
}]) |
observer.disconnect() |
done() |
- }).observe({entryTypes: ['server']}) |
+ }).observe({entryTypes: ['resource']}) |
var img = document.createElement('img') |
img.id = 'two' |