chromium/third_party/blink/web_tests/fast/dom/Window/Location/location-override-toString-using-defineGetter.html

<html>
<head>
    <script src="../../../../resources/js-test.js"></script>
    <script src="resources/location-tests-functions.js"></script>
</head>
<body>
<script>
    try {
        window.location.__defineGetter__("toString", function () {
            return function() { return "haxored"; }
        });
    } catch (e) { }

    var result = normalizeURL(String(window.location));
    var correctValue = normalizeURL(document.URL);
    shouldBe("result", "correctValue");
</script>
</body>
</html>