mirror of https://github.com/apache/lucene.git
SOLR-9107: When creating a randomized SSL test config, 100% effective odds of using SSL and/or client auth should never be trumped by chance.
This commit is contained in:
parent
18ac2978a9
commit
86c053dd10
|
@ -105,9 +105,9 @@ public @interface RandomizeSSL {
|
|||
// even if we know SSL is disabled, always consume the same amount of randomness
|
||||
// that way all other test behavior should be consistent even if a user adds/removes @SuppressSSL
|
||||
|
||||
final boolean useSSL = TestUtil.nextInt(LuceneTestCase.random(), 0, 1000) <
|
||||
final boolean useSSL = TestUtil.nextInt(LuceneTestCase.random(), 0, 999) <
|
||||
(int)(1000 * getEffectiveOdds(ssl, LuceneTestCase.TEST_NIGHTLY, LuceneTestCase.RANDOM_MULTIPLIER));
|
||||
final boolean useClientAuth = TestUtil.nextInt(LuceneTestCase.random(), 0, 1000) <
|
||||
final boolean useClientAuth = TestUtil.nextInt(LuceneTestCase.random(), 0, 999) <
|
||||
(int)(1000 * getEffectiveOdds(clientAuth, LuceneTestCase.TEST_NIGHTLY, LuceneTestCase.RANDOM_MULTIPLIER));
|
||||
|
||||
return new SSLTestConfig(useSSL, useClientAuth);
|
||||
|
|
Loading…
Reference in New Issue