- From: Kris Krueger via cvs-syncmail <cvsmail@w3.org>
- Date: Sun, 10 Jan 2010 23:49:21 +0000
- To: public-html-commits@w3.org
Update of /sources/public/html5/tests/submission/Microsoft/windowobject In directory hutz:/tmp/cvs-serv19257/submission/Microsoft/windowobject Added Files: security_location_0.htm Log Message: Create simple folder structure and simple test case for testing the window object. --- NEW FILE: security_location_0.htm --- <!DOCTYPE html> <html> <head> <title>HTML 5 Test Suite: Window Object Security</title> <link rel="author" title="Microsoft" href="http://www.microsoft.com/" /> <link rel="help" href="http://www.w3.org/TR/html5/browsers.html" /> <meta name="assert" content="access location object from different origins doesn't raise SECURITY_ERR exception" /> </head> <body> <div id='testdescription'>Test passes if the word PASS appears below.</div> <script type="text/javascript"> function RunTest() { // Add more tests upon passing increment the 'count' var ExpectedPasses = 1; var ActualPasses = 0; ActualPasses = locationObjectTest(); if (ExpectedPasses == ActualPasses) { document.getElementById('testresult').innerText = 'Pass'; } document.getElementById('testspassed').innerText = ActualPasses + "/" + ExpectedPasses; } function locationObjectTest() { var frame = document.getElementById('testframe'); try { frame.setAttribute('onload', ''); frame.contentWindow.location = 'http://dev.w3.org/'; return 1; } catch(exc) { return 0; } } </script> <span id='testresult'>FAIL</span> <span id='testspassed'>0</span> <iframe id='testframe' src="http://www.w3.org/" style="visibility: hidden; width: 0px; height:0px;" onload="RunTest()">Test Frame</iframe> </body> </html>
Received on Sunday, 10 January 2010 23:49:22 UTC