Return-Path: Delivered-To: apmail-ant-user-archive@www.apache.org Received: (qmail 22671 invoked from network); 16 Aug 2006 19:38:03 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 16 Aug 2006 19:38:03 -0000 Received: (qmail 35160 invoked by uid 500); 16 Aug 2006 19:37:58 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 35121 invoked by uid 500); 16 Aug 2006 19:37:57 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 35110 invoked by uid 99); 16 Aug 2006 19:37:57 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Aug 2006 12:37:57 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of lists@nabble.com designates 72.21.53.35 as permitted sender) Received: from [72.21.53.35] (HELO talk.nabble.com) (72.21.53.35) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Aug 2006 12:37:56 -0700 Received: from [72.21.53.38] (helo=jubjub.nabble.com) by talk.nabble.com with esmtp (Exim 4.50) id 1GDRCp-0003bk-EE for user@ant.apache.org; Wed, 16 Aug 2006 12:37:35 -0700 Message-ID: <5839099.post@talk.nabble.com> Date: Wed, 16 Aug 2006 12:37:35 -0700 (PDT) From: cmose To: user@ant.apache.org Subject: Re: classsnotfound exception with junit ant task In-Reply-To: <44E36C71.6070605@wolfram.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit References: <5838070.post@talk.nabble.com> <44E36C71.6070605@wolfram.com> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Joel, thanks much for the comments the typo was merely a typo in my transcription of the build file from a printout to here (it's on an isolated development network). There are no classloaders in use elsewhere that I'm familiar with (short of anything in use by junit). I'll check your recommendation about seeing if the class can indeed be loaded. (although I will amend that - I'm using the commons Digester and I've really no clue what that's using, although that is not involved in loading up this particular class). I edited the buildfile to run just the one class that failed previously when the whole suite was ran (from ant, again, running this from eclipse shows 0 problems). The one testcase fails again outright. Joel Klein wrote: > > cmose wrote: > >>classpath.project is defined thusly: >> >> --->this is the bin directory for >>class files >> ---> a temporary location for >>jar libraries >> >> >> > Where in this classpath is the missing class supposed to be found? If > it's supposed to be in the second pathelement above, there's a couple > things to check. > > The "Lirbaries" is a typo of "Libraries" (check what the actual > directory is called). Also, I don't know if the wildcard (*.jar) is > allowed in a path attribute value. If not, then that pathelement might > not be doing anything. > >>Now the obnoxious thing is this, Ant runs the junit tests and manages to get >>through 65 out of the 72 testcases before throwing the classnotfound >>exception. Furthermore, >>The class it's saying it can't find, it found in a testcase it ran previous >>to the failed testcase (e.g., ClassNotFoundException: MyClass, MyClass was >>already exercised in a previous testcase that the ant junit task ran without >>hiccup). >> >> > Was MyClass "exercised" the same way that the failed test uses it? I > wonder if it's possible that MyClass appears to be exercised in the > passing test but isn't. A simple statement like > System.out.println(MyClass.class.getName()) should force it to be loaded > so you can confirm whether it can be found or not. > > Are there by any chance any classloaders involved in this whole mess > that could be finding MyClass a different way than the classpath in the > test that uses it but doesn't fail? > > -- > Joel Klein [Online at http://jfkbits.blogspot.com] > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: user-unsubscribe@ant.apache.org > For additional commands, e-mail: user-help@ant.apache.org > > > -- View this message in context: http://www.nabble.com/classsnotfound-exception-with-junit-ant-task-tf2117062.html#a5839099 Sent from the Ant - Users forum at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org