Skip to content

Improve test feedback by logging the availability checks for OpenSSL and Tomcat Native libraries when they're missing#970

Open
csutherl wants to merge 1 commit intoapache:mainfrom
csutherl:add-warnings-for-missing-openssl-tcnative
Open

Improve test feedback by logging the availability checks for OpenSSL and Tomcat Native libraries when they're missing#970
csutherl wants to merge 1 commit intoapache:mainfrom
csutherl:add-warnings-for-missing-openssl-tcnative

Conversation

@csutherl
Copy link
Copy Markdown
Member

When running the tests without OpenSSL or Tomcat Native installed, there are several things happening without a clear explanation (without having to dig into individual test outputs):

  • OpenSSL cipher tests are silently excluded via build configuration
  • Tomcat Native tests are skipped via Assume.assumeTrue() checks
  • Users only see "Skipped: N" in test results, which requires looking into which were skipped
  • There's no proactive feedback about these missing libraries

Adding a warning when the libraries are missing allows you to check the target output to confirm that natives are being included in the tests without prior knowledge of which tests would be skipped when they're missing.

When either are unavailable, the tests are silently skipped or
excluded without a clear explanation to the user. The new warning
makes it obvious that the OpenSSL or Tomcat Native tests will
be skipped without having the look for which tests were skipped.
@dsoumis
Copy link
Copy Markdown
Member

dsoumis commented Mar 27, 2026

If tomcat-native is installed system-wide for example /usr/lib as is currently in Fedora, JVM will load it but the test.apr.loc check will fail.

@csutherl
Copy link
Copy Markdown
Member Author

You're right. We could document setting test.apr.loc to the local binaries as a requirement to get the benefit of the check, but given that it doesn't actually do anything if it fails to find it and the library will still load at runtime, the message being inaccurate is the only issue, right?

@csutherl
Copy link
Copy Markdown
Member Author

On second thought, the best option is to create a small class to load it at runtime to confirm it actually loads rather than string matching env vars...otherwise there's always the potential for runtime issues that you can't check for. I can add a java library path check, but it's still not completely accurate if there's any runtime errors.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants