Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(420)

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/xmlhttprequest/send-entity-body-basic.html

Issue 2723583005: Support XMLHttpRequest.send(URLSearchParams) (Closed)
Patch Set: rebased upto r454567 Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <!doctype html>
2 <html>
3 <head>
4 <title>XMLHttpRequest: send() - data argument</title>
5 <script src="/resources/testharness.js"></script>
6 <script src="/resources/testharnessreport.js"></script>
7 <link rel="help" href="https://xhr.spec.whatwg.org/#the-send()-method" data- tested-assertations="/following::ol/li[4]" />
8 </head>
9 <body>
10 <div id="log"></div>
11 <script>
12 // Taken from http://w3c-test.org/XMLHttpRequest/send-entity-body-basic.ht m
13
14 function request(input, output) {
15 test(function() {
16 var client = new XMLHttpRequest()
17 client.open("POST", "resources/echo-content.php", false)
18 client.send(input)
19 assert_equals(client.responseText, output)
20 }, document.title + " (" + output + ")")
21 }
22 request(1, "1")
23 request(10000000, "10000000")
24 request([2,2], "2,2")
25 request(false, "false")
26 request("A\0A", "A\0A")
27 request(new URLSearchParams([[1, 2], [3, 4]]), "1=2&3=4")
28 </script>
29 </body>
30 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698