summary refs log tree commit diff stats
path: root/tests
diff options
context:
space:
mode:
authorflywind <43030857+xflywind@users.noreply.github.com>2020-12-27 04:59:32 -0600
committerGitHub <noreply@github.com>2020-12-27 11:59:32 +0100
commit689504081f476ec23ebfd7123ad2f8b27c387a97 (patch)
tree3d290fd319da7b6ba2657ec9df2dc6ab46ac3d0a /tests
parent2bdc479622c465e570fdb87df112dd56ddc9030f (diff)
downloadNim-689504081f476ec23ebfd7123ad2f8b27c387a97.tar.gz
follow #15357 and move decodeQuery (#15860)
* follow #15357 and move decodeQuery
* solve problem one
* minor
* deprecate decodeData
* add changelog and since
* add testcase for decodeQuery
Diffstat (limited to 'tests')
-rw-r--r--tests/stdlib/tdecodequery.nim7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/stdlib/tdecodequery.nim b/tests/stdlib/tdecodequery.nim
new file mode 100644
index 000000000..ae180742f
--- /dev/null
+++ b/tests/stdlib/tdecodequery.nim
@@ -0,0 +1,7 @@
+import std/[uri, sequtils]
+
+
+block:
+  doAssert toSeq(decodeQuery("a=1&b=0")) == @[("a", "1"), ("b", "0")]
+  doAssertRaises(UriParseError):
+    discard toSeq(decodeQuery("a=1&b=2c=6"))