<!DOCTYPE html> | |
<body> | |
<script src="../resources/runner.js"></script> | |
<script> | |
var urls = PerfTestRunner.loadFile("resources/final-url-en").split("\n"); | |
var anchor = document.createElement("a"); | |
PerfTestRunner.measureRunsPerSecond({ | |
description: "Measures performance of URL parsing by setting the href attribute on an <a> tag to many different URLs.", | |
run: function() { | |
for (var x = 0; x < urls.length; x++) { | |
anchor.href = urls[x]; | |
} | |
} | |
}); | |
</script> | |
</body> |