Skip to content

Commit

Permalink
Always shutdown test resources after running a @QuarkusMain test
Browse files Browse the repository at this point in the history
Fixes: #26882
  • Loading branch information
geoand committed Jul 26, 2022
1 parent 0075ba0 commit ef00fec
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -214,16 +214,16 @@ private int doJavaStart(ExtensionContext context, Class<? extends QuarkusTestPro
if (!InitialConfigurator.DELAYED_HANDLER.isActivated()) {
activateLogging();
}

throw e;
} finally {
try {
if (testResourceManager != null) {
testResourceManager.close();
}
} catch (Exception ex) {
e.addSuppressed(ex);
} catch (Exception e) {
System.err.println("Unable to shutdown resource: " + e.getMessage());
}
throw e;
} finally {

uninstallLoggerRedirect();
QuarkusConsole.uninstallRedirects();
if (originalCl != null) {
Expand Down

0 comments on commit ef00fec

Please sign in to comment.