java.lang.SecurityException

Test code should never call System.exit()


Solutions on the web98

Solution icon of github
Test code should never call System.exit()

Solution icon of oraclecommunity
via Oracle Community by 3004, 1 year ago
System.exit() not allowed

Solution icon of googlegroups
via Google Groups by Daniel Spiewak, 1 year ago
Use of System.exit() is forbidden!

Solution icon of github
Use of System.exit() is forbidden!

Solution icon of web
via nabble.com by Unknown author, 4 months ago
Intercepted System.exit() from a class other than the GUIChooser. Please ignore.

Solution icon of stackoverflow
Crypto-J has entered an inoperable state, an internal FIPS 140 self-verification test has failed</p> <pre><code>at com.rsa.cryptoj.s.vd.c(Unknown Source)

Solution icon of stackoverflow
JAR should not contain JNLP-INF/APPLICATION_TEMPLATE.JNLP

Solution icon of web
via JIRA by Leo Lüker, 1 year ago
Isolated process not allowed to call getContentProvider

Solution icon of web
Isolated process not allowed to call getContentProvider

Solution icon of googlegroups
via Google Groups by comhari, 1 year ago
Request failed to pass the crumb test

Stack trace

  • java.lang.SecurityException: Test code should never call System.exit() at com.google.testing.junit.runner.util.GoogleTestSecurityManager.checkExit(GoogleTestSecurityManager.java:36) at java.lang.Runtime.exit(Runtime.java:107) at java.lang.System.exit(System.java:971) at com.google.devtools.common.options.OptionsParser.parseAndExitUponError(OptionsParser.java:193) at com.google.devtools.common.options.OptionsParser.parseAndExitUponError(OptionsParser.java:172) at com.google.devtools.build.android.ideinfo.PackageParser.parseArgs(PackageParser.java:163) at com.google.devtools.build.android.ideinfo.PackageParserTest.testHandlesOldFormat(PackageParserTest.java:272) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47) at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44) at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17) at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26) at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229) at org.junit.runners.ParentRunner.run(ParentRunner.java:309) at com.google.testing.junit.runner.junit4.CancellableRequestFactory$CancellableRunner.run(CancellableRequestFactory.java:89) at org.junit.runner.JUnitCore.run(JUnitCore.java:160) at org.junit.runner.JUnitCore.run(JUnitCore.java:138) at com.google.testing.junit.runner.junit4.JUnit4Runner.run(JUnit4Runner.java:114) at com.google.testing.junit.runner.BazelTestRunner.runTestsInSuite(BazelTestRunner.java:152) at com.google.testing.junit.runner.BazelTestRunner.main(BazelTestRunner.java:91)

Write tip

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

Users with the same issue

You are the first who have seen this exception. Write a tip to help other users and build your expert profile.