@@ -1,17 +1,12 @@
<project default="tes t" xmlns:au="antlib:org.apache.ant.antunit">
<project default="antuni t" xmlns:au="antlib:org.apache.ant.antunit">
<import file="../../../antunit-base.xml"/>
<description>
<description>
In which we test interesting aspects of scripting.
In which we test interesting aspects of scripting.
The targeted language is javascript; this lets us run without
The targeted language is javascript; this lets us run without
additions on Java6+.
additions on Java6+.
</description>
</description>
<target name="test">
<au:antunit>
<fileset file="${ant.file}"/>
<au:plainlistener/>
</au:antunit>
</target>
<target name="tearDown">
<target name="tearDown">
</target>
</target>
@@ -34,7 +29,6 @@
<property name="prop"
<property name="prop"
value='self.log("Ant version =${ant.version}");project.setNewProperty("property","live");' />
value='self.log("Ant version =${ant.version}");project.setNewProperty("property","live");' />
<presetdef name="assertPropSet">
<presetdef name="assertPropSet">
<au:assertPropertyEquals name="property" value="live" />
<au:assertPropertyEquals name="property" value="live" />
</presetdef>
</presetdef>
@@ -42,22 +36,19 @@
<!--purely to test that everything works -->
<!--purely to test that everything works -->
<target name="testInline">
<target name="testInline">
<js > self.log("Hello");</js>
<js>self.log("Hello");</js>
<scripttest/>
<scripttest/>
</target>
</target>
<target name="testStringResource">
<target name="testStringResource">
<js >
<js>
<string value='self.log("Ant version =${ant.version}");' />
<string value='self.log("Ant version =${ant.version}");' />
</js>
</js>
<scripttest/>
<scripttest/>
</target>
</target>
<target name="testStringResourceRef">
<target name="testStringResourceRef">
<js >
<js>
<string refid="script.code" />
<string refid="script.code" />
</js>
</js>
<scripttest/>
<scripttest/>
@@ -65,27 +56,26 @@
</target>
</target>
<target name="testStringResourceInline">
<target name="testStringResourceInline">
<js >
<string >
<js>
<string>
self.log("Ant version =${ant.version}");
self.log("Ant version =${ant.version}");
project.setNewProperty("property","live");
project.setNewProperty("property","live");
</string>
</string>
</js>
</js>
<scripttest/>
<scripttest/>
<assertPropSet />
<assertPropSet/>
</target>
</target>
<target name="testPropertyResource">
<target name="testPropertyResource">
<js>
<js>
<propertyresource name="prop" />
<propertyresource name="prop" />
</js>
</js>
<scripttest/>
<scripttest/>
<assertPropSet />
<assertPropSet/>
</target>
</target>
<target name="testMixedResources">
<target name="testMixedResources">
<js >
<js>
<string refid="script.code" />
<string refid="script.code" />
<propertyresource name="prop" />
<propertyresource name="prop" />
<string >
<string >
@@ -95,5 +85,4 @@
<scripttest/>
<scripttest/>
<assertPropSet name="property2" />
<assertPropSet name="property2" />
</target>
</target>
</project>
</project>