mirror of https://github.com/apache/lucene.git
SOLR-13747: New TestSSLTestConfig.testFailIfUserRunsTestsWithJVMThatHasKnownSSLBugs() to give people running tests more visibility if/when they use a known-buggy JVM causing most SSL tests to silently SKIP
(cherry picked from commit ec9780c8aa
)
This commit is contained in:
parent
4df2702cdb
commit
e979255ca7
|
@ -205,6 +205,9 @@ Other Changes
|
|||
|
||||
* SOLR-11492: Clean up /solr/cloud-dev scripts and provide a single well documented script (Gus Heck, Robert Bunch)
|
||||
|
||||
* SOLR-13747: New TestSSLTestConfig.testFailIfUserRunsTestsWithJVMThatHasKnownSSLBugs() to give people running
|
||||
tests more visibility if/when they use a known-buggy JVM causing most SSL tests to silently SKIP. (hossman)
|
||||
|
||||
================== 8.2.0 ==================
|
||||
|
||||
Consult the LUCENE_CHANGES.txt file for additional, low level, changes in this release.
|
||||
|
|
|
@ -20,6 +20,8 @@ package org.apache.solr.util;
|
|||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.lucene.util.Constants;
|
||||
|
||||
import org.apache.solr.SolrTestCase;
|
||||
|
||||
public class TestSSLTestConfig extends SolrTestCase {
|
||||
|
@ -84,4 +86,19 @@ public class TestSSLTestConfig extends SolrTestCase {
|
|||
|
||||
}
|
||||
|
||||
public void testFailIfUserRunsTestsWithJVMThatHasKnownSSLBugs() {
|
||||
// NOTE: If there is some future JVM version, where all available "ea" builds are known to be buggy,
|
||||
// but we still want to be able to use for running tests (ie: via jenkins) to look for *other* bugs,
|
||||
// then those -ea versions can be "white listed" here...
|
||||
|
||||
try {
|
||||
SSLTestConfig.assumeSslIsSafeToTest();
|
||||
} catch (org.junit.AssumptionViolatedException ave) {
|
||||
fail("Current JVM (" + Constants.JVM_NAME + " / " + Constants.JVM_VERSION +
|
||||
") is known to have SSL Bugs. Other tests that (explicitly or via randomization) " +
|
||||
" use SSL will be SKIPed");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue