blob: 5f93433416b1a40efe7fa38389dc5a54a587add4 [file] [log] [blame]
<!DOCTYPE html>
<html>
<head>
<!-- Programmatically converted from a WebKit Reftest, please forgive resulting idiosyncracies.-->
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline' 'self' 'unsafe-eval'; connect-src 'self';">
<title>worker-set-timeout-blocked</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="../support/logTest.sub.js?logs=[]"></script>
<script src='../support/alertAssert.sub.js?alerts=["setTimeout blocked"]'></script>
</head>
<body>
<script>
window.addEventListener('securitypolicyviolation', function(e) {
log('Fail');
});
try {
var worker = new Worker('/content-security-policy/script-src/support/worker-set-timeout.js');
worker.onmessage = function(event) {
alert_assert(event.data);
};
} catch (e) {
alert_assert(e);
}
</script>
<div id="log"></div>
</body>
</html>