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

Side by Side Diff: LayoutTests/fast/domurl/url-query-append.html

Issue 141003005: Old CL related to URL query (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 11 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | LayoutTests/fast/domurl/url-query-constructor.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE HTML>
2 <meta charset="utf-8">
3 <link rel="help" href="http://url.spec.whatwg.org/#dom-urlquery-append">
4 <script src="../../resources/testharness.js"></script>
5 <script src="../../resources/testharnessreport.js"></script>
6 <script>
7
8 test(function() {
9 var q = new URLQuery();
10 q.append('a', 'b');
11 assert_equals(q + '', 'a=b');
12
13 q.append('a', 'b');
14 assert_equals(q + '', 'a=b&a=b');
15
16 q.append('a', 'c');
17 assert_equals(q + '', 'a=b&a=b&a=c');
18 }, 'Append same name');
19
20 test(function() {
21 var q = new URLQuery();
22 q.append('', '');
23 assert_equals(q + '', '=');
24
25 q.append('', '');
26 assert_equals(q + '', '=&=');
27 }, 'Append empty strings');
28
29 test(function() {
30 var q = new URLQuery();
31 q.append(null, null);
32 assert_equals(q + '', 'null=null');
33
34 q.append(null, null);
35 assert_equals(q + '', 'null=null&null=null');
36 }, 'Append null');
37
38 </script>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/fast/domurl/url-query-constructor.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698