[ https://issues.apache.org/jira/browse/LUCENE-1529?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12698907#action_12698907 ]
Shai Erera commented on LUCENE-1529: ------------------------------------ Perhaps that's related: target test-tag has this step: {code} <!-- compile tag tests against tag jar --> <compile-test-macro srcdir="${tags.dir}/${tag}/src/test" destdir="${build.dir}/${tag}/classes/test" test.classpath="tag.test.classpath"/> {code} Notice that test.classpath is set to tag.test.classpath, which is defined as: {code} <path id="tag.test.classpath"> <path refid="demo.classpath"/> <path refid="junit-path"/> <pathelement location="${build.dir}/${tag}/classes/test"/> <pathelement location="${build.dir}/${tag}/${tag}.jar"/> </path> {code} "demo.classpath" includes build/classes/demo as well as build/classes/java, which includes the current trunk's build classes. If I change the definition to rely only on tag.jar, demo classes and junit jar: {code} <path id="tag.test.classpath"> <path refid="junit-path"/> <pathelement location="${build.dir}/classes/demo"/> <pathelement location="${build.dir}/${tag}/${tag}.jar"/> </path> {code} I get errors like this: {code} [javac] Compiling 128 source files to D:\dev\lucene\lucene-trunk\build\lucene_2_4_back_compat_tests_20090320\classes\test [javac] D:\dev\lucene\lucene-trunk\tags\lucene_2_4_back_compat_tests_20090320\src\test\org\apache\lucene\index\TestIndexReaderReopen.java:323: cannot find symbol [javac] symbol : method getSequentialSubReaders() [javac] location: class org.apache.lucene.index.MultiSegmentReader [javac] IndexReader[] subReaders0 = ((MultiSegmentReader) reader0).getSequentialSubReaders(); [javac] ^ [javac] D:\dev\lucene\lucene-trunk\tags\lucene_2_4_back_compat_tests_20090320\src\test\org\apache\lucene\index\TestIndexReaderReopen.java:335: cannot find symbol [javac] symbol : method getSequentialSubReaders() [javac] location: class org.apache.lucene.index.MultiSegmentReader [javac] IndexReader[] subReaders1 = ((MultiSegmentReader) reader1).getSequentialSubReaders(); [javac] ^ {code} That's because tag.jar's MultiSegmentReader does not have a getSequentialSubReaders method, however TestIndexReaderReopen calls it. Is that ok? Anyway, can it be that the classes/java in the classpath cause this change to not fail? > back-compat tests ("ant test-tag") should test JAR drop-in-ability > ------------------------------------------------------------------ > > Key: LUCENE-1529 > URL: https://issues.apache.org/jira/browse/LUCENE-1529 > Project: Lucene - Java > Issue Type: New Feature > Components: Build > Affects Versions: 2.9 > Reporter: Michael McCandless > Assignee: Michael Busch > Priority: Minor > Fix For: 2.9 > > Attachments: lucene-1529.patch > > > We now test back-compat with "ant test-tag", which is very useful for > catching breaks in back compat before committing. > However, that currently checks out "src/test" sources and then > compiles them against the trunk JAR, and runs the tests. Whereas our > back compat policy: > http://wiki.apache.org/lucene-java/BackwardsCompatibility > states that no recompilation is required on upgrading to a new JAR. > Ie you should be able to drop in the new JAR in place of your old one > and things should work fine. > So... we should fix "ant test-tag" to: > * Do full checkout of core sources & tests from the back-compat-tag > * Compile the JAR from the back-compat sources > * Compile the tests against that back-compat JAR > * Swap in the trunk JAR > * Run the tests -- 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: java-dev-unsubscr...@lucene.apache.org For additional commands, e-mail: java-dev-h...@lucene.apache.org