Re: Question about usage of LuceneTestCase

2018-08-27 Thread Tomoko Uchida
> i haven't looked closely into what exactly that "useFactory(null)" call > does, but it's probably worth getting to the bottom of the failures and > *IF* it's tied to some specific dir type or codec, using annotations to > supress them -- rather then just eliminating all directory randomization.

Re: Question about usage of LuceneTestCase

2018-08-27 Thread Chris Hostetter
: Current version of Luke supports FS based directory implementations only. : (I think it will be better if future versions support non-FS based custom : implementations, such as HdfsDirectoryFactory for users who need it.) : Disabling the randomization, at least for now, sounds reasonable to me

Re: Question about usage of LuceneTestCase

2018-08-22 Thread Tomoko Uchida
> You don't really have to figure out exactly what the combinations are, > just execute the test with the "reproduce with" flags set, cut/paste > the error message at the root of your local Solr source tree in a > command prompt. > ant test -Dtestcase=CommitsImplTest > -Dtests.method=testGetSegme

Re: Question about usage of LuceneTestCase

2018-08-22 Thread Michael Sokolov
It looks to me as if this test is asserting that the segment in an index it just created has some attributes, but in fact it does not. Perhaps there is a codec that does not store any attributes with its segments, and Luke does not expect this, and maybe the codec is being selected randomly by the

Re: Question about usage of LuceneTestCase

2018-08-22 Thread Michael Sokolov
Here's a seed that fails for me consistently in IntelliJ: "FEF692F43FE50191:656E22441676701C" running CommitsImplTest. Warning: I have a bunch of local changes that might have perturbed the randomness so possibly it might not reproduce for others. I just run the tests, open the "Edit Configuration

Re: Question about usage of LuceneTestCase

2018-08-22 Thread Erick Erickson
bq. My understanding at this point is (though it may be a repeat of your words,) first we should find out the combinations behind the failures. If there are any particular patterns, there could be bugs, so we should fix it. You don't really have to figure out exactly what the combinations are, jus

Re: Question about usage of LuceneTestCase

2018-08-22 Thread Tomoko Uchida
Can I ask one more question. 4> If MIke's intuition that it's one of the file system randomizations that occasionally gets hit _and_ you determine that that's an invalid test case (and for Luke requiring that the FS-basesd tests are all that are necessary may be fine) I'm pretty sure you you can d

Re: Question about usage of LuceneTestCase

2018-08-22 Thread Tomoko Uchida
Thanks for your kind explanations, sorry of course I know what is the randomization seed, but your description and instruction is exactly what I wanted. > The randomization can cause different > combinations of "stuff" to happen. Say the locale is randomized to > Turkish and a token is also rando

Re: Question about usage of LuceneTestCase

2018-08-21 Thread Erick Erickson
The pseudo-random generator in the Lucene test framework is used to randomize lots of test conditions, we're talking about the file system implementation here, but there are lots of others. Whenever you see a call to random().whatever, that's the call to the framework's method. But here's the thin

Re: Question about usage of LuceneTestCase

2018-08-21 Thread Tomoko Uchida
Thanks a lot for your information & insights, I will try to reproduce the errors and investigate the results. And, maybe I should learn more about internal of the test framework, I'm not familiar with it and still do not understand what does "seed" means exactly in this context. Regards, Tomoko

Re: Question about usage of LuceneTestCase

2018-08-21 Thread Erick Erickson
Couple of things (and I know you've been around for a while, so pardon me if it's all old hat to you): 1> if you run the entire "reproduce with" line and can get a consistent failure, then you are half way there, nothing is as frustrating as not getting failures reliably. The critical bit is often

Re: Question about usage of LuceneTestCase

2018-08-21 Thread Tomoko Uchida
Hi, Mike Thanks for sharing your experiments. > CommitsImplTest.testListCommits > CommitsImplTest.testGetCommit_generation_notfound > CommitsImplTest.testGetSegments > DocumentsImplTest.testGetDocumentFIelds I also found CommitsImplTest and DocumentsImplTest fail frequently, especially CommitsIm

Re: Question about usage of LuceneTestCase

2018-08-21 Thread Michael Sokolov
I was running these luke tests a bunch and found the following tests fail intermittently; pretty frequently. Once I @Ignore them I can get a consistent pass: CommitsImplTest.testListCommits CommitsImplTest.testGetCommit_generation_notfound CommitsImplTest.testGetSegments DocumentsImplTest.testGet

Question about usage of LuceneTestCase

2018-08-21 Thread Tomoko Uchida
Hello, Could you give me some advice or comments about usage of LuceneTestCase. Some of our unit tests extending LuceneTestCase fail by assertion error -- sometimes, randomly. I suppose we use LuceneTestCase in inappropriate way, but cannot find out how to fix it. Here is some information about