Auto merge of #19528 - asajeffrey:test-perf-measure-loadEventEnd, r=avadacatavra

Capture loadEventEnd in test-perf

<!-- Please describe your changes on the following line: -->

Capture perf-test data after the load event has finished firing.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes do not require tests because this is test infrastructure

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/19528)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2017-12-18 16:54:07 -06:00 committed by GitHub
commit 89f9af88a3

View file

@ -41,7 +41,9 @@ if (document.readyState === "complete") {
printPerfTiming()
window.close();
} else {
window.addEventListener('load', printPerfTiming);
window.addEventListener('load', function () {
window.setTimeout(printPerfTiming, 0);
});
var timeout = 5;
window.setTimeout(function() {
print("[PERF] Timeout after " + timeout + " min. Force stop");