The testsuite is just not scalable, Bill, and is inappropriate for module level unit tests. Having the compile take 5-10 minutes for running just one test is ludicrous.
If you want to object, object to the change note when I announced this facility. I will see about getting all the module tests to run with the main testsuite and included in the report. ricardo, all my tests just used stuff from build/tests or build/gen/tests (or whatever its named). I think we need an additional src/test-resource directory in each module for this purpose. We need a definition in buildfragments/defaults.ent and to include it in the _default:tests target. david jencks On 2003.02.14 11:26 Bill Burke wrote: > Please put these tests in the testsuite. We need nightly reports on the > stability of JBoss. Plus, if they aren't integrated with testsuite you > risk > somebody breaking your code with a new change to the core. > > Again, put these tests in testuiste > > Thanks, > > XXXXXXXXXXXXXXXX > Bill Burke > Chief Architect > JBoss Group, LLC > XXXXXXXXXXXXXXXX > > > > -----Original Message----- > > From: [EMAIL PROTECTED] > > [mailto:[EMAIL PROTECTED]]On Behalf Of > > Ricardo Argüello > > Sent: Friday, February 14, 2003 9:58 AM > > To: [EMAIL PROTECTED] > > Subject: [JBoss-dev] The new "tests" target > > > > > > Hi, > > > > I'm trying to use the new "tests" target for JBoss-Media (CVS > > module: jboss-media). > > > > I need to access files with media to do some unit testing. I'm > > doing it this way: > > > > >From > > jboss-head/media/src/test/org/jboss/media/JBossMediaUnitTestCase.java: > > ... > > ClassLoader classLoader = Thread.currentThread().getContextClassLoader(); > > InputStream inputStream = classLoader.getResourceAsStream(resourceName); > > ... > > > > Most of the code was copied from the > > "jboss-head/testsuite/src/main/org/jboss/test/cmp2/lob" testcase. > > In that testcase, getResourceAsStream works with files under > src/resources > > > > resourceName is in my case "data/image.png". I've tried putting > > the file in src/main, src/resources and src/test with no luck: I > > can't read the file. > > > > I can run the test from Eclipse, running JBossMediaUnitTestCase > > as a Junit test, "build tests" gives me Errors: > > > > <testcase name="testMediaBeanProperties" time="0.016"> > > <error > > type="java.lang.NullPointerException">java.lang.NullPointerExcepti > > on at > > org.jboss.media.JBossMediaUnitTestCase.createFileFromResource(JBos > > sMediaUnitTestCase.java:196) at > > org.jboss.media.JBossMediaUnitTestCase.setUp(JBossMediaUnitTestCas > > e.java:61)</error> > > </testcase> > > <testcase name="testMediaFormatRegistry" time="0.0"> > > <error > > type="java.lang.NullPointerException">java.lang.NullPointerExcepti > > on at > > org.jboss.media.JBossMediaUnitTestCase.createFileFromResource(JBos > > sMediaUnitTestCase.java:196) at > > org.jboss.media.JBossMediaUnitTestCase.setUp(JBossMediaUnitTestCas > > e.java:61)</error> > > </testcase> > > <testcase name="testHeaderExtraction" time="0.0"> > > <error > > type="java.lang.NullPointerException">java.lang.NullPointerExcepti > > on at > > org.jboss.media.JBossMediaUnitTestCase.createFileFromResource(JBos > > sMediaUnitTestCase.java:196) at > > org.jboss.media.JBossMediaUnitTestCase.setUp(JBossMediaUnitTestCas > > e.java:61)</error> > > > > > > *Maybe* some change needs to be added to > > tools/etc/buildfragments/targets.ent? > > > > Where should I put files to be readed with > > ClassLoader.getResourceAsStream(...) form within a JUnit testcase > > to be run with the new "tests" target? > > > > You can find all the code in the jboss-media CVS module. > > > > Thanks in advance, > > > > Ricardo Argüello > > [EMAIL PROTECTED] > > www.freeroller.net/page/ricardo > > > > -- > > I took the red pill. > > > > > > > > > > ------------------------------------------------------- > > This SF.NET email is sponsored by: FREE SSL Guide from Thawte > > are you planning your Web Server Security? Click here to get a FREE > > Thawte SSL guide and find the answers to all your SSL security issues. > > http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0026en > > _______________________________________________ > > Jboss-development mailing list > > [EMAIL PROTECTED] > > https://lists.sourceforge.net/lists/listinfo/jboss-development > > > > ------------------------------------------------------- > This SF.NET email is sponsored by: FREE SSL Guide from Thawte > are you planning your Web Server Security? Click here to get a FREE > Thawte SSL guide and find the answers to all your SSL security issues. > http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0026en > _______________________________________________ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-development > > ------------------------------------------------------- This SF.NET email is sponsored by: FREE SSL Guide from Thawte are you planning your Web Server Security? Click here to get a FREE Thawte SSL guide and find the answers to all your SSL security issues. http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0026en _______________________________________________ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development