ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bradley Williams <>
Subject JUnit Task Error
Date Thu, 14 Dec 2000 16:39:36 GMT
This test runs fine out side of ant !
I get this error when running build with the junit task.
Any ideas on what might be wrong ?

    [junit] Testcase: testRegAppServer took 0.18 sec
    [junit]     Caused an ERROR
    [junit] loader constraints violated when linking org/xml/sax/InputSource
    [junit] java.lang.LinkageError: loader constraints violated when linking
org/xml/sax/InputSource class
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at junit.framework.TestCase.runBare(
    [junit]     at junit.framework.TestResult$1.protect(
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at
    [junit]     at


-----Original Message-----
From: James Cook []
Sent: Thursday, December 14, 2000 10:50 AM
Subject: Ant 2.0 Consideration

Since Ant 2.0 is being discussed, I thought I should offer an opinion.

Most IDE's in use by developers display packages, source files, and support
files such as jsp, html, properties, gif, jpg, etc.  There are some exciting
possibilities that can be achieved via Ant integration on these projects.
However, because of the package/file metaphor used by these products, it
with Ant's task-based metaphor. Note that this clash doesn't preclude Ant
integration, but it forces the developer into working with Ant instead of
working with his/her files. Many power users won't care about this, but it
be a deterrent to more junior developers.

Most IDE's will automatically compile all Java source files added to a
Likewise, some will copy certain nodes (.properties, .gif) to an output
directory automatically. Some IDE's allow the developer to invoke pre- or
post-processing functions on a particular file. Ant already has more support
(and definitely more flexibility) for supporting these additional tasks than
IDE on the market.

In order for Ant to be integrated to the point that I am hoping, it will be
necessary for several things to change in the Ant design.

1. A two-way Java class structure including Projects, Targets and Tasks. I
that there is a move towards this in Anteater. This approach IMHO is much
than exposing the DOM and using that as a read/write source. There is too
opportunity for ambiguity between DOM and the resulting Tasks.

2. Consistent support for how a Task handles File discovery needs to be
enforced. The MatchingTask is a big step forward in this process, but not
Tasks use it. I may be wrong, but the Fileset concept seems to fly in the
of MatchingTask as well. It seems that File discovery can be achieved in two
very different manners.

3. The reason I think File discovery is so important comes back to the fact
these IDEs utilitize a package/file structure. In order for Ant to be fully
integrated, I need to be able to ask each Task if a particular file is
by the Task. For example, given a particular File object, I should be able
ask a Copy Task if it will include this task. Since the Copy Task does not
extend MatchingTask, this becomes impossible. Perhaps, a solution is to
Tasks to implement an isIncluded(File[])/isExcluded(File[]) method.

4. The converse of #3 would be the ability for a given Task object to
include or
exclude a specific file. This capability can be supported by the methods
doInclude(File[]) or doExclude(File[]).

I am interested in feedback on these issues.


View raw message