mirror of
https://github.com/servo/servo.git
synced 2025-08-20 04:45:33 +01:00
Update web-platform-tests to revision e8bfc205e36ad699601212cd50083870bad9a75d
This commit is contained in:
parent
65dd6d4340
commit
ccdb0a3458
1428 changed files with 118036 additions and 9786 deletions
|
@ -10,9 +10,38 @@
|
|||
<div id="target0"></div>
|
||||
<script>
|
||||
test(function() {
|
||||
assert_throws(new TypeError(), function() {new Touch();}, "Touch constructor requires initialize dictionary");
|
||||
assert_throws(new TypeError(), function() {new Touch({});}, "Touch constructor requires identifier and target");
|
||||
}, "Create a Touch object with insufficient properties");
|
||||
var testIdentifier = 0;
|
||||
var testTarget = document.getElementById('target0');
|
||||
|
||||
assert_throws(new TypeError(), function() {new Touch();}, "Touch constructor with no argument");
|
||||
assert_throws(new TypeError(), function() {new Touch(null);}, "Touch constructor with null argument");
|
||||
assert_throws(new TypeError(), function() {new Touch(undefined);}, "Touch constructor with undefined argument");
|
||||
assert_throws(new TypeError(), function() {new Touch({});}, "Touch constructor with empty object");
|
||||
assert_throws(new TypeError(), function() {new Touch({
|
||||
identifier: testIdentifier
|
||||
});}, "Touch constructor with only identifier");
|
||||
assert_throws(new TypeError(), function() {new Touch({
|
||||
target: testTarget
|
||||
});}, "Touch constructor with only target");
|
||||
}, "Touch constructor with insufficient properties");
|
||||
|
||||
test(function() {
|
||||
var testIdentifier = 0;
|
||||
var testTarget = document.getElementById('target0');
|
||||
|
||||
assert_throws(new TypeError(), function() {new Touch({
|
||||
identifier: testIdentifier,
|
||||
target: null
|
||||
});}, "Touch constructor with null target");
|
||||
assert_throws(new TypeError(), function() {new Touch({
|
||||
identifier: testIdentifier,
|
||||
target: undefined
|
||||
});}, "Touch constructor with undefined target");
|
||||
assert_throws(new TypeError(), function() {new Touch({
|
||||
identifier: testIdentifier,
|
||||
target: location
|
||||
});}, "Touch constructor with Location target");
|
||||
}, "Touch constructor with non-EventTarget target");
|
||||
|
||||
test(function() {
|
||||
var testIdentifier = 74;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue