<style>
    svg {
        width: 100px;
        height: 100px;
        pointer-events: all;
    }
</style>
<body>
    <svg>
        <rect width="100" height="100" fill="red"/>
    </svg>
    <script>
        if (window.testRunner)
            testRunner.dumpAsText();

        var root = document.getElementsByTagName("svg")[0];
        var rect = root.createSVGRect();
        rect.x = 10;
        rect.y = 10;
        rect.width = 1;
        rect.height = 1;
        
        var list = root.getIntersectionList(rect, null);
        document.write("<h3>Number of intersected elements = " + list.length + ".</h3>") 
    </script>
</body>
