You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bo...@apache.org on 2017/12/10 07:48:05 UTC
ant git commit: seems Sun's native2ascii doesn't always close input
properly on win
Repository: ant
Updated Branches:
refs/heads/1.9.x 67f29ce0c -> 4796589e8
seems Sun's native2ascii doesn't always close input properly on win
Project: http://git-wip-us.apache.org/repos/asf/ant/repo
Commit: http://git-wip-us.apache.org/repos/asf/ant/commit/4796589e
Tree: http://git-wip-us.apache.org/repos/asf/ant/tree/4796589e
Diff: http://git-wip-us.apache.org/repos/asf/ant/diff/4796589e
Branch: refs/heads/1.9.x
Commit: 4796589e815565d9bc93d2c79500bbb01dcd0dd4
Parents: 67f29ce
Author: Stefan Bodewig <bo...@apache.org>
Authored: Sun Dec 10 08:47:19 2017 +0100
Committer: Stefan Bodewig <bo...@apache.org>
Committed: Sun Dec 10 08:47:19 2017 +0100
----------------------------------------------------------------------
.../antunit/taskdefs/optional/native2ascii-test.xml | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ant/blob/4796589e/src/tests/antunit/taskdefs/optional/native2ascii-test.xml
----------------------------------------------------------------------
diff --git a/src/tests/antunit/taskdefs/optional/native2ascii-test.xml b/src/tests/antunit/taskdefs/optional/native2ascii-test.xml
index 560ead3..8eff37c 100644
--- a/src/tests/antunit/taskdefs/optional/native2ascii-test.xml
+++ b/src/tests/antunit/taskdefs/optional/native2ascii-test.xml
@@ -18,6 +18,11 @@
<project default="antunit" xmlns:au="antlib:org.apache.ant.antunit">
<import file="../../antunit-base.xml" />
+ <target name="tearDown" depends="antunit-base.tearDown"
+ if="n2a.tmp">
+ <delete dir="${n2a.tmp}" failonerror="false" deleteonexit="true"/>
+ </target>
+
<target name="-create-native2ascii-adapter">
<mkdir dir="${input}/org/example"/>
<echo file="${input}/org/example/Adapter.java"><![CDATA[
@@ -88,9 +93,10 @@ public class Adapter implements Native2AsciiAdapter {
</target>
<target name="-setup-UTF8-To-ASCII" depends="-real-test-macros">
- <mkdir dir="${input}"/>
+ <property name="n2a.tmp" location="${input}/../ant-native2ascii-test"/>
+ <mkdir dir="${n2a.tmp}"/>
<mkdir dir="${output}"/>
- <echo file="${input}/umlauts.properties" encoding="UTF-8">äöü=ÄÖÜ</echo>
+ <echo file="${n2a.tmp}/umlauts.properties" encoding="UTF-8">äöü=ÄÖÜ</echo>
<property name="umlauts.expected"
value="\u00e4\u00f6\u00fc=\u00c4\u00d6\u00dc"/>
</target>
@@ -98,14 +104,14 @@ public class Adapter implements Native2AsciiAdapter {
<target name="testUTF8-To-ASCII-sun" depends="-setup-UTF8-To-ASCII"
description="https://bz.apache.org/bugzilla/show_bug.cgi?id=59855"
unless="jdk9+">
- <native2ascii-def implementation="sun"/>
+ <native2ascii-def implementation="sun" src="${n2a.tmp}"/>
<assertTranslatedOutput file="umlauts.properties" encoding="ASCII"
expected="${umlauts.expected}"/>
</target>
<target name="testUTF8-To-ASCII-builtin" depends="-setup-UTF8-To-ASCII"
description="https://bz.apache.org/bugzilla/show_bug.cgi?id=59855">
- <native2ascii-def implementation="builtin"/>
+ <native2ascii-def implementation="builtin" src="${n2a.tmp}"/>
<assertTranslatedOutput file="umlauts.properties" encoding="ASCII"
expected="${umlauts.expected}"/>
</target>