mirror of
https://github.com/servo/servo.git
synced 2025-08-07 06:25:32 +01:00
Cargoify servo
This commit is contained in:
parent
db2f642c32
commit
c6ab60dbfc
1761 changed files with 8423 additions and 2294 deletions
18
tests/content/test_click_prevent.html
Normal file
18
tests/content/test_click_prevent.html
Normal file
|
@ -0,0 +1,18 @@
|
|||
<html>
|
||||
<head>
|
||||
<script src="./harness.js"></script>
|
||||
<a id="foo" href="/nonexistent">test link</a>
|
||||
<script>
|
||||
var link = document.getElementById('foo');
|
||||
link.addEventListener('click', function(ev) {
|
||||
ev.preventDefault();
|
||||
});
|
||||
var ev = new Event('click', {bubbles: true, cancelable: true});
|
||||
link.dispatchEvent(ev);
|
||||
setTimeout(function() {
|
||||
is(true, true, "load probably would have occurred by now");
|
||||
finish();
|
||||
}, 500);
|
||||
</script>
|
||||
</head>
|
||||
</html>
|
Loading…
Add table
Add a link
Reference in a new issue