[
https://issues.apache.org/jira/browse/SOLR-10916?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16054522#comment-16054522
]
Hoss Man commented on SOLR-10916:
---------------------------------
As a quick example: here are a few tests that extend LuceneTestCase and use
MiniSolrCloudCluster (they seem to have been copied/pasted from the
TestMiniSolrCloudCluster which was explicitly written as a demo for external
clients that might want ot use MiniSolrCloudCluster even w/o using JUnit.
These tests should all be changed to subclass SolrCloudTestCase...
{code}
hossman@tray:~/lucene/dev/solr/core [master] $ find -name \*.java | xargs grep
-l "extends LuceneTestCase" | xargs grep -l MiniSolrCloud
./src/test/org/apache/solr/cloud/TestAuthenticationFramework.java
./src/test/org/apache/solr/cloud/TestSolrCloudWithKerberosAlt.java
./src/test/org/apache/solr/cloud/TestMiniSolrCloudCluster.java
{code}
...that last test, TestMiniSolrCloudCluster, is still left over from SOLR-8961
and should be renamed to represent what it does
(TestCollectionsAPIViaSolrCloudCluster or some such)
> Any Solr test using MiniSolrCloud or Solr Core's should extend SolrTestCaseJ4
> -----------------------------------------------------------------------------
>
> Key: SOLR-10916
> URL: https://issues.apache.org/jira/browse/SOLR-10916
> Project: Solr
> Issue Type: Bug
> Security Level: Public(Default Security Level. Issues are Public)
> Reporter: Hoss Man
>
> We have a non-trivial number of tests that extend LuceneTestCase directly.
> For "utility" method minded tests, this is fine - but for any test that wants
> to instantiate re-use shared config files to instantiate SolrCores, or
> instances of MiniSolrCloudCluster, this makes these tests really cumbersome
> to maintain and deal with because htye don't leverage the existing
> randomization setup logic in SolrTestCaseJ4.
> we should fix these tests where applicable
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]