summaryrefslogtreecommitdiff
path: root/test/files/run/json.scala
diff options
context:
space:
mode:
authorAntonio Cunei <antonio.cunei@epfl.ch>2011-11-07 09:55:10 +0000
committerAntonio Cunei <antonio.cunei@epfl.ch>2011-11-07 09:55:10 +0000
commitda929738ccfcf21cc3d8fdb9ce7734e59c6847f0 (patch)
tree90e335ca1fb60fde22ad345df72aeb0f08aace22 /test/files/run/json.scala
parentc4e1b28cf79f73e4f8972263efb85ee879c39ebd (diff)
downloadscala-da929738ccfcf21cc3d8fdb9ce7734e59c6847f0.tar.gz
scala-da929738ccfcf21cc3d8fdb9ce7734e59c6847f0.tar.bz2
scala-da929738ccfcf21cc3d8fdb9ce7734e59c6847f0.zip
Backport of r25948
Diffstat (limited to 'test/files/run/json.scala')
-rw-r--r--test/files/run/json.scala16
1 files changed, 8 insertions, 8 deletions
diff --git a/test/files/run/json.scala b/test/files/run/json.scala
index 0a141dc38c..6d25999e9c 100644
--- a/test/files/run/json.scala
+++ b/test/files/run/json.scala
@@ -28,7 +28,7 @@ object Test extends Application {
case Some(parsed) => println("Passed: " + sortJSON(parsed))
}
}
-
+
def printJSON(given : String, expected : Any) {
JSON parseFull given match {
case None => println("Parse failed for \"%s\"".format(given))
@@ -63,11 +63,11 @@ object Test extends Application {
// The library should recurse into arrays to find objects (ticket #2207)
printJSON("""[{"a": "team"},{"b": 52}]""", List(Map("a" -> "team"), Map("b" -> 52.0)))
-
+
// The library should differentiate between empty maps and lists (ticket #3284)
- printJSON("{}", Map())
+ printJSON("{}", Map())
printJSON("[]", List())
-
+
// Lists should be returned in the same order as specified
printJSON("[4,1,3,2,6,5,8,7]", List[Double](4,1,3,2,6,5,8,7))
@@ -110,7 +110,7 @@ object Test extends Application {
)
)
-
+
printJSON(sample1, sample1Obj)
println
@@ -146,7 +146,7 @@ object Test extends Application {
// from http://json.org/example.html
val sample3 = """
{"web-app": {
- "servlet": [
+ "servlet": [
{
"servlet-name": "cofaxCDS",
"servlet-class": "org.cofax.cds.CDSServlet",
@@ -202,7 +202,7 @@ object Test extends Application {
{
"servlet-name": "cofaxAdmin",
"servlet-class": "org.cofax.cds.AdminServlet"},
-
+
{
"servlet-name": "fileServlet",
"servlet-class": "org.cofax.cds.FileServlet"},
@@ -229,7 +229,7 @@ object Test extends Application {
"cofaxAdmin": "/admin/*",
"fileServlet": "/static/*",
"cofaxTools": "/tools/*"},
-
+
"taglib": {
"taglib-uri": "cofax.tld",
"taglib-location": "/WEB-INF/tlds/cofax.tld"}