mirror of
https://github.com/servo/servo.git
synced 2025-08-15 10:25:32 +01:00
Update web-platform-tests to revision 3f3849c5d05f9350fad0b06d3bb3ae30d7e18d14
This commit is contained in:
parent
9a7e2663e8
commit
f767403c00
310 changed files with 8134 additions and 895 deletions
|
@ -100,11 +100,6 @@ testToastElement((toast) => {
|
|||
assertToastNotShown(toast);
|
||||
}, 'setting `toast.open` to some falsy value on a shown toast will hide the toast');
|
||||
|
||||
testToastElement((toast) => {
|
||||
toast.toggleAttribute('open');
|
||||
assert_true(toast.open);
|
||||
}, 'toggling `open` on a hidden toast sets `toast.open` to true');
|
||||
|
||||
testToastElementAsync((t, toast) => {
|
||||
toast.toggleAttribute('open', true);
|
||||
|
||||
|
@ -115,7 +110,18 @@ testToastElementAsync((t, toast) => {
|
|||
}, 'toggling open attribute does not start timeout');
|
||||
|
||||
testToastElement((toast) => {
|
||||
const permitted_properties = ['constructor', 'show', 'hide', 'toggle', 'open', 'action', 'closeButton'];
|
||||
const permitted_properties = ['constructor', 'show', 'hide', 'toggle', 'open', 'action', 'closeButton', 'type'];
|
||||
assert_array_equals(permitted_properties.sort(), Object.getOwnPropertyNames(toast.__proto__).sort());
|
||||
}, 'toast only exposes certain properties');
|
||||
|
||||
testToastElement((toast) => {
|
||||
assert_false(toast.hasAttribute('type'));
|
||||
assert_equals(toast.type, '');
|
||||
}, 'default type is empty string without attribute present');
|
||||
|
||||
testToastElement((toast) => {
|
||||
toast.type = 'info';
|
||||
assert_equals(toast.type, '');
|
||||
assert_equals(toast.getAttribute('type'), 'info');
|
||||
}, 'info was briefly a valid type, but no longer is, so it will return empty string');
|
||||
</script>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue