diff options
author | Alex Cruise <alex@cluonflux.com> | 2012-03-08 23:41:58 -0800 |
---|---|---|
committer | Alex Cruise <alex@metaforsoftware.com> | 2012-03-15 14:31:08 -0700 |
commit | e7ea29cc0b3c55d7880b767f8c442d8bf3cd0dea (patch) | |
tree | 09008ce8463b33b068210128cdaf508c91b08195 /test/files/jvm | |
parent | 24d8760030ea9379131104561929d19e437a9793 (diff) | |
download | scala-e7ea29cc0b3c55d7880b767f8c442d8bf3cd0dea.tar.gz scala-e7ea29cc0b3c55d7880b767f8c442d8bf3cd0dea.tar.bz2 scala-e7ea29cc0b3c55d7880b767f8c442d8bf3cd0dea.zip |
SI-1118 WIP
Diffstat (limited to 'test/files/jvm')
-rwxr-xr-x | test/files/jvm/deprecation/t1118.scala | 21 | ||||
-rwxr-xr-x[-rw-r--r--] | test/files/jvm/interpreter.check | 2 | ||||
-rwxr-xr-x[-rw-r--r--] | test/files/jvm/t0632.check | 24 | ||||
-rwxr-xr-x | test/files/jvm/t1118.check | 10 | ||||
-rwxr-xr-x[-rw-r--r--] | test/files/jvm/xml01.check | 4 | ||||
-rwxr-xr-x[-rw-r--r--] | test/files/jvm/xml03syntax.check | 4 |
6 files changed, 48 insertions, 17 deletions
diff --git a/test/files/jvm/deprecation/t1118.scala b/test/files/jvm/deprecation/t1118.scala index e69de29bb2..4464e51f89 100755 --- a/test/files/jvm/deprecation/t1118.scala +++ b/test/files/jvm/deprecation/t1118.scala @@ -0,0 +1,21 @@ +import scala.xml._
+
+object Test {
+ def main(args: Array[String]) {
+ println(<xml:group>
+<hi/> <!-- literal short -->
+<there></there> <!-- literal long -->
+<guys who="you all"></guys> <!-- literal long with attribute-->
+<hows it="going"/> <!-- literal short with attribute -->
+<this>scala stuff is pretty cool</this> <!-- literal not empty -->
+</xml:group>)
+
+ println(Elem(null, "bob", Null, TopScope, false) ++ Text(" ") ++ Comment("programmatic long"))
+
+ println(Elem(null, "dobbs", Null, TopScope, true) ++ Text(" ") ++ Comment("programmatic short"))
+
+ println(Elem(null, "is", Attribute("really", Text("yep"), Null), TopScope, true) ++ Text(" ") ++ Comment ("programmatic short with attribute"))
+
+ println(Elem(null, "slack", Attribute("sing", Text("it"), Null), TopScope, false) ++ Text(" ") ++ Comment ("programmatic long with attribute"))
+ }
+}
\ No newline at end of file diff --git a/test/files/jvm/interpreter.check b/test/files/jvm/interpreter.check index 196a769a17..243c9aa3be 100644..100755 --- a/test/files/jvm/interpreter.check +++ b/test/files/jvm/interpreter.check @@ -301,7 +301,7 @@ scala> <a> /></a> res8: scala.xml.Elem = <a> -<b c="c" d="dd"></b></a> +<b c="c" d="dd"/></a> scala> diff --git a/test/files/jvm/t0632.check b/test/files/jvm/t0632.check index 3185410a75..681bc9da92 100644..100755 --- a/test/files/jvm/t0632.check +++ b/test/files/jvm/t0632.check @@ -1,12 +1,12 @@ -<foo x="&"></foo> -<foo x="&"></foo> -<foo x="&"></foo> -<foo x="&"></foo> -<foo x="&amp;"></foo> -<foo x="&amp;"></foo> -<foo x="&amp;"></foo> -<foo x="&amp;"></foo> -<foo x="&&"></foo> -<foo x="&&"></foo> -<foo x="&&"></foo> -<foo x="&&"></foo> +<foo x="&"/> +<foo x="&"/> +<foo x="&"/> +<foo x="&"/> +<foo x="&amp;"/> +<foo x="&amp;"/> +<foo x="&amp;"/> +<foo x="&amp;"/> +<foo x="&&"/> +<foo x="&&"/> +<foo x="&&"/> +<foo x="&&"/> diff --git a/test/files/jvm/t1118.check b/test/files/jvm/t1118.check index e69de29bb2..f8a17e0195 100755 --- a/test/files/jvm/t1118.check +++ b/test/files/jvm/t1118.check @@ -0,0 +1,10 @@ +<hi/> <!-- literal short -->
+<there></there> <!-- literal long -->
+<guys who="you all"></guys> <!-- literal long with attribute-->
+<hows it="going"/> <!-- literal short with attribute -->
+<this>scala stuff is pretty cool</this> <!-- literal not empty -->
+
+<bob></bob> <!--programmatic long-->
+<dobbs/> <!--programmatic short-->
+<is really="yep"/> <!--programmatic short with attribute-->
+<slack sing="it"></slack> <!--programmatic long with attribute-->
\ No newline at end of file diff --git a/test/files/jvm/xml01.check b/test/files/jvm/xml01.check index 5e82e9a729..d78e6df410 100644..100755 --- a/test/files/jvm/xml01.check +++ b/test/files/jvm/xml01.check @@ -3,6 +3,6 @@ xpath \ xpath \\ DESCENDANTS <book><author>Peter Buneman</author><author>Dan Suciu</author><title>Data on ze web</title></book> -- group nodes -<f><a></a><b></b><c></c></f> -<a></a><f><a></a><b></b><c></c></f><a></a><b></b><c></c> +<f><a/><b/><c/></f> +<a/><f><a/><b/><c/></f><a/><b/><c/> attribute value normalization diff --git a/test/files/jvm/xml03syntax.check b/test/files/jvm/xml03syntax.check index 9fbedc2ae6..edcdbdd2ba 100644..100755 --- a/test/files/jvm/xml03syntax.check +++ b/test/files/jvm/xml03syntax.check @@ -22,5 +22,5 @@ true 2 4 -node=<elem key="<b>hello</b>"></elem>, key=Some(<b>hello</b>) -node=<elem></elem>, key=None +node=<elem key="<b>hello</b>"/>, key=Some(<b>hello</b>) +node=<elem/>, key=None |