Skip to content

Commit

Permalink
Bug 1516063 [wpt PR 14637] - html, xhr: Add tests for 'formdata' even…
Browse files Browse the repository at this point in the history
…t, a=testonly

Automatic update from web-platform-tests
html, xhr: Add tests for 'formdata' event (#14637)

Specification PR: whatwg/html#4239

--

wpt-commits: c547389199647f1736be244a7ca5a874da692430
wpt-pr: 14637

UltraBlame original commit: c71f7d3fa10b69185c90a1537bb49989a0fd4604
  • Loading branch information
marco-c committed Oct 3, 2019
1 parent f5a3121 commit 1373d2e
Show file tree
Hide file tree
Showing 7 changed files with 1,755 additions and 0 deletions.
24 changes: 24 additions & 0 deletions testing/web-platform/tests/html/dom/interfaces.https.html
Original file line number Diff line number Diff line change
Expand Up @@ -372,6 +372,9 @@
'
dom
'
'
xhr
'
]
async
idlArray
Expand Down Expand Up @@ -1853,6 +1856,27 @@
validity
'
]
FormDataEvent
:
[
'
new
FormDataEvent
(
"
formdata
"
{
formData
:
new
FormData
(
)
}
)
'
]
HTMLDetailsElement
:
[
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,311 @@
/
/
https
:
/
/
html
.
spec
.
whatwg
.
org
/
multipage
/
form
-
control
-
infrastructure
.
html
#
the
-
formdataevent
-
interface
test
(
(
)
=
>
{
let
fd
=
new
FormData
(
)
;
let
typeError
=
new
TypeError
(
)
;
assert_throws
(
typeError
(
)
=
>
{
new
FormDataEvent
(
)
}
'
0
arguments
'
)
;
assert_throws
(
typeError
(
)
=
>
{
new
FormDataEvent
(
'
foo
'
)
}
'
1
argument
'
)
;
assert_throws
(
typeError
(
)
=
>
{
new
FormDataEvent
(
fd
fd
)
}
'
2
invalid
arguments
'
)
;
assert_throws
(
typeError
(
)
=
>
{
new
FormDataEvent
(
'
foo
'
null
)
}
'
Null
dictionary
'
)
;
assert_throws
(
typeError
(
)
=
>
{
new
FormDataEvent
(
'
foo
'
undefined
)
}
'
Undefined
dictionary
'
)
;
assert_throws
(
typeError
(
)
=
>
{
new
FormDataEvent
(
'
foo
'
{
formData
:
null
}
)
}
'
Null
formData
'
)
;
assert_throws
(
typeError
(
)
=
>
{
new
FormDataEvent
(
'
foo
'
{
formData
:
undefined
}
)
}
'
Undefined
formData
'
)
;
assert_throws
(
typeError
(
)
=
>
{
new
FormDataEvent
(
'
foo
'
{
formData
:
'
bar
'
}
)
}
'
Wrong
type
of
formData
'
)
;
}
'
Failing
FormDataEvent
constructor
'
)
;
test
(
(
)
=
>
{
let
fd
=
new
FormData
(
)
;
let
event
=
new
FormDataEvent
(
'
bar
'
{
formData
:
fd
bubbles
:
true
}
)
;
assert_equals
(
event
.
formData
fd
)
;
assert_true
(
event
.
bubbles
)
;
}
'
Successful
FormDataEvent
constructor
'
)
;
Loading

0 comments on commit 1373d2e

Please sign in to comment.