ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jaikiran Pai <jai.forums2...@gmail.com>
Subject Re: ant git commit: Inline buildfile names, make search easier
Date Mon, 30 Apr 2018 04:43:36 GMT
What purpose is this change serving?

-Jaikiran


On 30/04/18 10:08 AM, gintas@apache.org wrote:
> Repository: ant
> Updated Branches:
>    refs/heads/master 0add85310 -> f3dfb7779
>
>
> Inline buildfile names, make search easier
>
> Project: http://git-wip-us.apache.org/repos/asf/ant/repo
> Commit: http://git-wip-us.apache.org/repos/asf/ant/commit/f3dfb777
> Tree: http://git-wip-us.apache.org/repos/asf/ant/tree/f3dfb777
> Diff: http://git-wip-us.apache.org/repos/asf/ant/diff/f3dfb777
>
> Branch: refs/heads/master
> Commit: f3dfb7779a528439a390ab09383cd8cb6b7e8307
> Parents: 0add853
> Author: Gintas Grigelionis <gintas@apache.org>
> Authored: Mon Apr 30 06:38:27 2018 +0200
> Committer: Gintas Grigelionis <gintas@apache.org>
> Committed: Mon Apr 30 06:38:27 2018 +0200
>
> ----------------------------------------------------------------------
>   .../apache/tools/ant/taskdefs/ExecTaskTest.java |  4 +---
>   .../apache/tools/ant/taskdefs/JavadocTest.java  |  6 +-----
>   .../apache/tools/ant/taskdefs/ParallelTest.java |  5 +----
>   .../tools/ant/taskdefs/PathConvertTest.java     |  4 +---
>   .../tools/ant/taskdefs/RmicAdvancedTest.java    |  4 +---
>   .../apache/tools/ant/taskdefs/SleepTest.java    |  3 +--
>   .../org/apache/tools/ant/taskdefs/WarTest.java  |  4 +---
>   .../tools/ant/taskdefs/optional/ANTLRTest.java  |  4 +---
>   .../taskdefs/optional/EchoPropertiesTest.java   | 21 ++++++--------------
>   .../tools/ant/taskdefs/optional/JavahTest.java  |  4 +---
>   .../tools/ant/taskdefs/optional/JspcTest.java   |  4 +---
>   .../ant/taskdefs/optional/Native2AsciiTest.java |  5 +----
>   .../taskdefs/optional/ReplaceRegExpTest.java    |  3 +--
>   .../taskdefs/optional/RhinoReferenceTest.java   |  3 +--
>   .../taskdefs/optional/SchemaValidateTest.java   |  7 +------
>   .../optional/XmlValidateCatalogTest.java        |  7 +------
>   .../ant/taskdefs/optional/XmlValidateTest.java  |  7 +------
>   .../taskdefs/optional/depend/DependTest.java    |  5 +----
>   .../ant/taskdefs/optional/image/ImageTest.java  |  3 +--
>   .../junit/XMLFormatterWithCDATAOnSystemOut.java |  3 +--
>   20 files changed, 25 insertions(+), 81 deletions(-)
> ----------------------------------------------------------------------
>
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/ExecTaskTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/ExecTaskTest.java b/src/tests/junit/org/apache/tools/ant/taskdefs/ExecTaskTest.java
> index fd92ded..cf30955 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/ExecTaskTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/ExecTaskTest.java
> @@ -44,8 +44,6 @@ public class ExecTaskTest {
>       @Rule
>       public BuildFileRule buildRule = new BuildFileRule();
>   
> -    private static final String BUILD_PATH = "src/etc/testcases/taskdefs/exec/";
> -    private static final String BUILD_FILE = BUILD_PATH + "exec.xml";
>       private static final int TIME_TO_WAIT = 1;
>       /** maximum time allowed for the build in milliseconds */
>       private static final int MAX_BUILD_TIME = 6000;
> @@ -60,7 +58,7 @@ public class ExecTaskTest {
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(BUILD_FILE);
> +        buildRule.configureProject("src/etc/testcases/taskdefs/exec/exec.xml");
>       }
>   
>       @Test
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/JavadocTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/JavadocTest.java b/src/tests/junit/org/apache/tools/ant/taskdefs/JavadocTest.java
> index f7a287d..cae8620 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/JavadocTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/JavadocTest.java
> @@ -28,13 +28,9 @@ public class JavadocTest {
>       @Rule
>       public final BuildFileRule buildRule = new BuildFileRule();
>   
> -    private static final String BUILD_PATH = "src/etc/testcases/taskdefs/javadoc/";
> -    private static final String BUILD_FILENAME = "javadoc.xml";
> -    private static final String BUILD_FILE = BUILD_PATH + BUILD_FILENAME;
> -
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(BUILD_FILE);
> +        buildRule.configureProject("src/etc/testcases/taskdefs/javadoc/javadoc.xml");
>       }
>   
>       // PR 38370
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/ParallelTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/ParallelTest.java b/src/tests/junit/org/apache/tools/ant/taskdefs/ParallelTest.java
> index eba49c9..c08564e 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/ParallelTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/ParallelTest.java
> @@ -52,14 +52,11 @@ public class ParallelTest {
>       /** Standard property value for the fail test */
>       public static final String FAILURE_MESSAGE = "failure";
>   
> -    /** the build file associated with this test */
> -    public static final String TEST_BUILD_FILE = "src/etc/testcases/taskdefs/parallel.xml";
> -
>       private Project p;
>       /** The JUnit setup method */
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(TEST_BUILD_FILE);
> +        buildRule.configureProject("src/etc/testcases/taskdefs/parallel.xml");
>           p = buildRule.getProject();
>       }
>   
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/PathConvertTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/PathConvertTest.java b/src/tests/junit/org/apache/tools/ant/taskdefs/PathConvertTest.java
> index f29dc12..8a706e6 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/PathConvertTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/PathConvertTest.java
> @@ -33,13 +33,11 @@ public class PathConvertTest {
>       @Rule
>       public final BuildFileRule buildRule = new BuildFileRule();
>   
> -    private static final String BUILD_PATH = "src/etc/testcases/taskdefs/";
>       private static final String BUILD_FILENAME = "pathconvert.xml";
> -    private static final String BUILD_FILE = BUILD_PATH + BUILD_FILENAME;
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(BUILD_FILE);
> +        buildRule.configureProject("src/etc/testcases/taskdefs/" + BUILD_FILENAME);
>       }
>   
>       @Test
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/RmicAdvancedTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/RmicAdvancedTest.java b/src/tests/junit/org/apache/tools/ant/taskdefs/RmicAdvancedTest.java
> index f162b2f..2322a36 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/RmicAdvancedTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/RmicAdvancedTest.java
> @@ -41,8 +41,6 @@ import static org.junit.Assume.assumeTrue;
>    */
>   public class RmicAdvancedTest {
>   
> -    private static final String TASKDEFS_DIR = "src/etc/testcases/taskdefs/rmic/";
> -
>       @Rule
>       public BuildFileRule buildRule = new BuildFileRule();
>   
> @@ -54,7 +52,7 @@ public class RmicAdvancedTest {
>        */
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(TASKDEFS_DIR + "rmic.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/rmic/rmic.xml");
>       }
>   
>       /**
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/SleepTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/SleepTest.java b/src/tests/junit/org/apache/tools/ant/taskdefs/SleepTest.java
> index 163d485..a1853c5 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/SleepTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/SleepTest.java
> @@ -31,12 +31,11 @@ public class SleepTest {
>       @Rule
>       public final BuildFileRule buildRule = new BuildFileRule();
>   
> -    private static final String TASKDEFS_DIR = "src/etc/testcases/taskdefs/";
>       private static final int ERROR_RANGE = 1000;
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(TASKDEFS_DIR + "sleep.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/sleep.xml");
>       }
>   
>       @Test
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/WarTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/WarTest.java b/src/tests/junit/org/apache/tools/ant/taskdefs/WarTest.java
> index 1513ac7..80d0df6 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/WarTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/WarTest.java
> @@ -32,15 +32,13 @@ import static org.junit.Assert.assertTrue;
>    *
>    */
>   public class WarTest {
> -    public static final String TEST_BUILD_FILE
> -        = "src/etc/testcases/taskdefs/war.xml";
>   
>       @Rule
>       public BuildFileRule buildRule = new BuildFileRule();
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(TEST_BUILD_FILE);
> +        buildRule.configureProject("src/etc/testcases/taskdefs/war.xml");
>       }
>   
>       /**
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/ANTLRTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/ANTLRTest.java b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/ANTLRTest.java
> index 895617f..efcbf01 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/ANTLRTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/ANTLRTest.java
> @@ -46,14 +46,12 @@ import static org.junit.Assert.assertThat;
>    */
>   public class ANTLRTest {
>   
> -    private static final String TASKDEFS_DIR = "src/etc/testcases/taskdefs/optional/antlr/";
> -
>       @Rule
>       public BuildFileRule buildRule = new BuildFileRule();
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(TASKDEFS_DIR + "antlr.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/antlr/antlr.xml");
>       }
>   
>       /**
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/EchoPropertiesTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/EchoPropertiesTest.java
b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/EchoPropertiesTest.java
> index bc298f8..f31ff46 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/EchoPropertiesTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/EchoPropertiesTest.java
> @@ -20,6 +20,7 @@ package org.apache.tools.ant.taskdefs.optional;
>   
>   import static org.hamcrest.Matchers.containsString;
>   import static org.junit.Assert.assertEquals;
> +import static org.junit.Assert.assertNotNull;
>   import static org.junit.Assert.assertNull;
>   import static org.junit.Assert.assertThat;
>   import static org.junit.Assert.assertTrue;
> @@ -51,7 +52,6 @@ import org.junit.rules.ExpectedException;
>    */
>   public class EchoPropertiesTest {
>   
> -    private static final String TASKDEFS_DIR = "src/etc/testcases/taskdefs/optional/";
>       private static final String GOOD_OUTFILE = "test.properties";
>       private static final String GOOD_OUTFILE_XML = "test.xml";
>       private static final String PREFIX_OUTFILE = "test-prefix.properties";
> @@ -65,7 +65,7 @@ public class EchoPropertiesTest {
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(TASKDEFS_DIR + "echoproperties.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/echoproperties.xml");
>           buildRule.getProject().setProperty("test.property", TEST_VALUE);
>       }
>   
> @@ -123,7 +123,7 @@ public class EchoPropertiesTest {
>           buildRule.executeTarget("testEchoToGoodFileXml");
>   
>           // read in the file
> -        File f = createRelativeFile(GOOD_OUTFILE_XML);
> +        File f = new File(buildRule.getProject().getBaseDir(), GOOD_OUTFILE_XML);
>           try (BufferedReader br = new BufferedReader(new FileReader(f))) {
>               assertTrue("did not encounter set property in generated file.", br.lines().anyMatch(line
>                       -> line.contains("<property name=\"test.property\" value=\""
+ TEST_VALUE + "\" />")));
> @@ -196,7 +196,9 @@ public class EchoPropertiesTest {
>   
>       protected Properties loadPropFile(String relativeFilename)
>               throws IOException {
> -        File f = createRelativeFile(relativeFilename);
> +        assertNotNull("Null property file name", relativeFilename);
> +        File f = new File(buildRule.getProject().getBaseDir(), relativeFilename);
> +        assertTrue("Did not create " + f.getAbsolutePath(), f.exists());
>           Properties props = new Properties();
>           try (InputStream in = new BufferedInputStream(new FileInputStream(f))) {
>               props.load(in);
> @@ -205,21 +207,10 @@ public class EchoPropertiesTest {
>       }
>   
>       protected void assertGoodFile() throws Exception {
> -        File f = createRelativeFile(GOOD_OUTFILE);
> -        assertTrue("Did not create " + f.getAbsolutePath(),
> -            f.exists());
>           Properties props = loadPropFile(GOOD_OUTFILE);
>           props.list(System.out);
>           assertEquals("test property not found ",
>                        TEST_VALUE, props.getProperty("test.property"));
>       }
>   
> -    protected String toAbsolute(String filename) {
> -        return createRelativeFile(filename).getAbsolutePath();
> -    }
> -
> -    protected File createRelativeFile(String filename) {
> -        return filename.equals(".") ? buildRule.getProject().getBaseDir()
> -                : new File(buildRule.getProject().getBaseDir(), filename);
> -    }
>   }
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/JavahTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/JavahTest.java b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/JavahTest.java
> index d58c080..edff2c0 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/JavahTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/JavahTest.java
> @@ -31,14 +31,12 @@ import static org.junit.Assume.assumeFalse;
>   
>   public class JavahTest {
>   
> -    private static final String BUILD_XML = "src/etc/testcases/taskdefs/optional/javah/build.xml";
> -
>       @Rule
>       public BuildFileRule buildRule = new BuildFileRule();
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(BUILD_XML);
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/javah/build.xml");
>       }
>   
>       @After
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/JspcTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/JspcTest.java b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/JspcTest.java
> index d4cdda9..436fd65 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/JspcTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/JspcTest.java
> @@ -47,8 +47,6 @@ import static org.junit.Assert.assertTrue;
>    */
>   public class JspcTest {
>   
> -    private static final String TASKDEFS_DIR = "src/etc/testcases/taskdefs/optional/";
> -
>       @Rule
>       public ExpectedException thrown = ExpectedException.none();
>   
> @@ -57,7 +55,7 @@ public class JspcTest {
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(TASKDEFS_DIR + "jspc.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/jspc.xml");
>        }
>   
>       @Test
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/Native2AsciiTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/Native2AsciiTest.java
b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/Native2AsciiTest.java
> index 0ea5d9b..a4a1890 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/Native2AsciiTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/Native2AsciiTest.java
> @@ -32,15 +32,12 @@ import static org.junit.Assert.assertTrue;
>   
>   public class Native2AsciiTest {
>   
> -    private static final String BUILD_XML =
> -        "src/etc/testcases/taskdefs/optional/native2ascii/build.xml";
> -
>       @Rule
>       public BuildFileRule buildRule = new BuildFileRule();
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(BUILD_XML);
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/native2ascii/build.xml");
>       }
>   
>       @After
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/ReplaceRegExpTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/ReplaceRegExpTest.java
b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/ReplaceRegExpTest.java
> index cbf278a..c214ce4 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/ReplaceRegExpTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/ReplaceRegExpTest.java
> @@ -39,14 +39,13 @@ import static org.junit.Assume.assumeTrue;
>    *
>    */
>   public class ReplaceRegExpTest {
> -    private static final String PROJECT_PATH = "src/etc/testcases/taskdefs/optional";
>   
>       @Rule
>       public BuildFileRule buildRule = new BuildFileRule();
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(PROJECT_PATH + "/replaceregexp.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/replaceregexp.xml");
>       }
>   
>       @Test
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/RhinoReferenceTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/RhinoReferenceTest.java
b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/RhinoReferenceTest.java
> index 41803de..34e5401 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/RhinoReferenceTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/RhinoReferenceTest.java
> @@ -34,8 +34,7 @@ public class RhinoReferenceTest {
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(
> -                "src/etc/testcases/taskdefs/optional/script_reference.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/script_reference.xml");
>       }
>   
>       @Test
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/SchemaValidateTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/SchemaValidateTest.java
b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/SchemaValidateTest.java
> index 1cb0451..c621e0e 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/SchemaValidateTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/SchemaValidateTest.java
> @@ -30,11 +30,6 @@ import org.junit.rules.ExpectedException;
>   
>   public class SchemaValidateTest {
>   
> -    /**
> -     * where tasks run
> -     */
> -    private static final String TASKDEFS_DIR = "src/etc/testcases/taskdefs/optional/";
> -
>       @Rule
>       public BuildFileRule buildRule = new BuildFileRule();
>   
> @@ -43,7 +38,7 @@ public class SchemaValidateTest {
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(TASKDEFS_DIR + "schemavalidate.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/schemavalidate.xml");
>       }
>   
>       /**
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/XmlValidateCatalogTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/XmlValidateCatalogTest.java
b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/XmlValidateCatalogTest.java
> index 33fa189..8f3caa4 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/XmlValidateCatalogTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/XmlValidateCatalogTest.java
> @@ -30,17 +30,12 @@ import org.junit.Test;
>    */
>   public class XmlValidateCatalogTest {
>   
> -    /**
> -     * where tasks run
> -     */
> -    private static final String TASKDEFS_DIR = "src/etc/testcases/taskdefs/optional/";
> -
>       @Rule
>       public BuildFileRule buildRule = new BuildFileRule();
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(TASKDEFS_DIR + "xmlvalidate.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/xmlvalidate.xml");
>       }
>   
>   
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/XmlValidateTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/XmlValidateTest.java
b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/XmlValidateTest.java
> index 30b2a00..6c97422 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/XmlValidateTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/XmlValidateTest.java
> @@ -34,11 +34,6 @@ import org.junit.rules.ExpectedException;
>    */
>   public class XmlValidateTest {
>   
> -    /**
> -     * where tasks run
> -     */
> -    private static final String TASKDEFS_DIR = "src/etc/testcases/taskdefs/optional/";
> -
>       @Rule
>       public BuildFileRule buildRule = new BuildFileRule();
>   
> @@ -47,7 +42,7 @@ public class XmlValidateTest {
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(TASKDEFS_DIR + "xmlvalidate.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/xmlvalidate.xml");
>       }
>   
>       /**
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/depend/DependTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/depend/DependTest.java
b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/depend/DependTest.java
> index d97afcc..023c36b 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/depend/DependTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/depend/DependTest.java
> @@ -47,9 +47,6 @@ import static org.junit.Assert.assertTrue;
>   public class DependTest {
>       public static final String RESULT_FILESET = "result";
>   
> -    public static final String TEST_BUILD_FILE
> -        = "src/etc/testcases/taskdefs/optional/depend/depend.xml";
> -
>       @Rule
>       public BuildFileRule buildRule = new BuildFileRule();
>   
> @@ -58,7 +55,7 @@ public class DependTest {
>   
>       @Before
>       public void setUp() {
> -        buildRule.configureProject(TEST_BUILD_FILE);
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/depend/depend.xml");
>       }
>   
>       /**
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/image/ImageTest.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/image/ImageTest.java
b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/image/ImageTest.java
> index 3fda82c..2d7f43c 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/image/ImageTest.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/image/ImageTest.java
> @@ -44,7 +44,6 @@ import static org.junit.Assume.assumeTrue;
>   public class ImageTest {
>   
>       private static final FileUtils FILE_UTILS = FileUtils.getFileUtils();
> -    private static final String TASKDEFS_DIR = "src/etc/testcases/taskdefs/optional/image/";
>       private static final String LARGEIMAGE = "largeimage.jpg";
>   
>       @Rule
> @@ -57,7 +56,7 @@ public class ImageTest {
>       public void setUp() {
>           /* JAI depends on internal API removed in Java 9 */
>           assumeFalse(JavaEnvUtils.isAtLeastJavaVersion(JavaEnvUtils.JAVA_9));
> -        buildRule.configureProject(TASKDEFS_DIR + "image.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/image/image.xml");
>       }
>   
>   
>
> http://git-wip-us.apache.org/repos/asf/ant/blob/f3dfb777/src/tests/junit/org/apache/tools/ant/taskdefs/optional/junit/XMLFormatterWithCDATAOnSystemOut.java
> ----------------------------------------------------------------------
> diff --git a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/junit/XMLFormatterWithCDATAOnSystemOut.java
b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/junit/XMLFormatterWithCDATAOnSystemOut.java
> index 64674a2..55aed16 100644
> --- a/src/tests/junit/org/apache/tools/ant/taskdefs/optional/junit/XMLFormatterWithCDATAOnSystemOut.java
> +++ b/src/tests/junit/org/apache/tools/ant/taskdefs/optional/junit/XMLFormatterWithCDATAOnSystemOut.java
> @@ -31,7 +31,6 @@ import static org.junit.Assert.assertThat;
>   
>   public class XMLFormatterWithCDATAOnSystemOut {
>   
> -    private static final String DIR = "src/etc/testcases/taskdefs/optional/junit";
>       private static final String REPORT =
>           "TEST-" + XMLFormatterWithCDATAOnSystemOut.class.getName() + ".xml";
>   
> @@ -61,7 +60,7 @@ public class XMLFormatterWithCDATAOnSystemOut {
>   
>       @Test
>       public void testBuildfile() throws IOException {
> -        buildRule.configureProject(DIR + "/cdataoutput.xml");
> +        buildRule.configureProject("src/etc/testcases/taskdefs/optional/junit/cdataoutput.xml");
>           if (buildRule.getProject().getProperty("cdata.inner") == null) {
>               // avoid endless loop
>               buildRule.executeTarget("run-junit");
>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message