summaryrefslogtreecommitdiff
path: root/test/files/run
diff options
context:
space:
mode:
authorGrzegorz Kossakowski <grzegorz.kossakowski@gmail.com>2013-02-25 15:08:28 -0800
committerGrzegorz Kossakowski <grzegorz.kossakowski@gmail.com>2013-02-25 15:08:28 -0800
commit3b85c3d22b9d62e9e07c53f235ae8e889581ddc8 (patch)
treed269d42c31fbcd9f39601772d36b9e63136ff717 /test/files/run
parent4cb1ee413a52f3fa1c85def20bf1143e8ef7d840 (diff)
parent8187debb7148483d991b7fa131e0c66cdee6e646 (diff)
downloadscala-3b85c3d22b9d62e9e07c53f235ae8e889581ddc8.tar.gz
scala-3b85c3d22b9d62e9e07c53f235ae8e889581ddc8.tar.bz2
scala-3b85c3d22b9d62e9e07c53f235ae8e889581ddc8.zip
Merge pull request #2149 from khernyo/issue/7074
SI-7074 Fix xml attribute sorting
Diffstat (limited to 'test/files/run')
-rw-r--r--test/files/run/t7074.check9
-rw-r--r--test/files/run/t7074.scala15
2 files changed, 24 insertions, 0 deletions
diff --git a/test/files/run/t7074.check b/test/files/run/t7074.check
new file mode 100644
index 0000000000..ab9cf11f16
--- /dev/null
+++ b/test/files/run/t7074.check
@@ -0,0 +1,9 @@
+<a/>
+<a b="2" c="3" d="1"/>
+<a b="2" c="4" d="1" e="3" f="5"/>
+<a b="5" c="4" d="3" e="2" f="1"/>
+<a b="1" c="2" d="3" e="4" f="5"/>
+<a a:b="2" a:c="3" a:d="1"/>
+<a a:b="2" a:c="4" a:d="1" a:e="3" a:f="5"/>
+<a a:b="5" a:c="4" a:d="3" a:e="2" a:f="1"/>
+<a a:b="1" a:c="2" a:d="3" a:e="4" a:f="5"/>
diff --git a/test/files/run/t7074.scala b/test/files/run/t7074.scala
new file mode 100644
index 0000000000..693a076a7a
--- /dev/null
+++ b/test/files/run/t7074.scala
@@ -0,0 +1,15 @@
+import scala.xml.Utility.sort
+
+object Test extends App {
+ println(sort(<a/>))
+ println(sort(<a d="1" b="2" c="3"/>))
+ println(sort(<a d="1" b="2" e="3" c="4" f="5"/>))
+ println(sort(<a f="1" e="2" d="3" c="4" b="5"/>))
+ println(sort(<a b="1" c="2" d="3" e="4" f="5"/>))
+
+ println(sort(<a a:d="1" a:b="2" a:c="3"/>))
+ println(sort(<a a:d="1" a:b="2" a:e="3" a:c="4" a:f="5"/>))
+ println(sort(<a a:f="1" a:e="2" a:d="3" a:c="4" a:b="5"/>))
+ println(sort(<a a:b="1" a:c="2" a:d="3" a:e="4" a:f="5"/>))
+}
+