Houston Putman created SOLR-17651:
-------------------------------------
Summary: Obfuscate System.exit(), remove direct usage
Key: SOLR-17651
URL: https://issues.apache.org/jira/browse/SOLR-17651
Project: Solr
Issue Type: Improvement
Components: cli, Tests
Reporter: Houston Putman
In SOLR-17379, we are removing the {{TestSecurityManager}} defined in Lucene
that prohibits the usage of System.exit() in unit testing. This is important,
since gradle will fail with very little information when a test does a
System.exit() call.
In Solr, the CLI will use System.exit() to fail and show the user. This makes
sense as a CLI, but not in a unit test. It would be great if we could create a
utility that can be called in Solr to mimic System.exit(), but in unit testing
throw an exception instead. Then we could add System.exit() to forbidden-apis,
and ensure that our testing code won't run into this.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]