[ https://issues.apache.org/jira/browse/LUCENE-930?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Hoss Man updated LUCENE-930: ---------------------------- Attachment: LUCENE-930.patch 1) rather then add empty src/test directories to contribs (which might confuse people: they might assume tests exist by seeing the dir, they might assume they didn't get the tests in their release since the dir is empty, they might svn remove the dirs not realizing it will break the build, etc...) i made the contrib-build.xml skip the compile-test and test targets if there are no tests. 2) Encountered a problem while testing the patch: tests in some contribs rely on the core tests files (spellchecker depends on the English class for example) and "ant clean test-contrib" doesn't ensure that the core tests are compiled (because build-contrib no longer depends on compile-test). I view this is really a problem with the way contrib dependencies are built and not the main build.xml ... on a clean checkout you should be able to do "cd contrib/foo; ant test" and have it automatically build all your dependencies (this already works for the core lucene jar because of the "build-lucene" task). so I made some additions to contrib-build.xml to support this (a "build-lucene-test" task), and the spellchecker contrib that needed it. 3) with Michael's encouragement, i went ahead and removed the "compile-test-contrib" target and just made "build-contrib" take care of it ... this involved adding a new "build-jar-and-tests" since contrib-crawl/subant only support a single target name ... this is much cleaner in my opinion then the old way where build-contrib would just run whatever the 'default' target was for each contrib (which could be named anything, and could do anything) .. now the expected semantics are clearer (although i'm open torenaming the target) ...but i ran into a slight snag because of the "javacc-uptodate-check" init depends on which doesn't work for "meta-contribs" like gdata and db that don't have a src dir ... the task even has a TODO that it really only needs to be done for a few contribs, so that looks like a good thing to fix to ... but i've got to run now. i'll try to update the patch a little later tonight (any feedback in the meantime would be appreciated) > fail build if contrib tests fail to compile > ------------------------------------------- > > Key: LUCENE-930 > URL: https://issues.apache.org/jira/browse/LUCENE-930 > Project: Lucene - Java > Issue Type: Bug > Components: Build > Affects Versions: 2.1 > Reporter: Hoss Man > Assignee: Hoss Man > Attachments: LUCENE-930.patch, LUCENE-930.patch > > > spinoff of LUCENE-885, from Steven's comments... > Looking at the current build (r545324) it looks like the some contrib > failures are getting swallowed. Things like lucli are throwing errors along > the lines of > [subant] /home/barronpark/smparkes/work/lucene/trunk/common-build.xml:366: > srcdir "/home/barronpark/smparkes/work/lucene/trunk/contrib/lucli/src/test" > does not exist! > but these don't make it back up to the top level status. > It looks like the current state will bubble up junit failures, but maybe not > build failures? > ... > It's "test-compile-contrib" (if you will) that fails and rather being > contrib-crawled, that's only done as the target of "test" in each contrib > directory, at which point, it's running in the protected contrib-crawl. > Easy enough to lift this loop into another target, e.g., build-contrib-test. > And that will start surfacing errors, which I can work through. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]