Commit c50f4ca1 authored by Richard Townsend's avatar Richard Townsend Committed by Chromium LUCI CQ

fix: attempt to further deflake prefetching test

Test did not properly filter non-resource performance events like paint
and longtask.

Bug: 901056, 1164166
Change-Id: Ib1b9737b7e720f721e8e25c5275bffe8aab5b7f4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2623208Reviewed-by: default avatarMason Freed <masonfreed@chromium.org>
Commit-Queue: Richard Townsend <richard.townsend@arm.com>
Cr-Commit-Position: refs/heads/master@{#842234}
parent ec6c7d8f
......@@ -16,11 +16,9 @@
window.addEventListener("message", function(msg) {
// Parse the Performance API data passed from the plain text iframe.
const entries = JSON.parse(msg.data);
const urls = [];
const resource_types = [];
for (const entry of entries) {
resource_types.push(entry.entryType);
urls.push(entry.name);
}
// If preloading is working correctly, should only see the text document
// represented in the performance information. A 'resource' type indicates
......@@ -33,8 +31,6 @@
}
}
assert_false(resource_found, "no resources should be present");
assert_equals(urls.length, 1);
assert_equals(urls[0].endsWith("avoid-prefetching-on-text-plain-inner.html"), true);
done();
});
prefetchingIframe.addEventListener('load', function() {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment