mirror of
https://github.com/vanitasvitae/Smack.git
synced 2024-11-26 05:52:06 +01:00
sinttest: log unexpected Throwables thrown by runTests()
Because we would not see those if the finally block also threw.
This commit is contained in:
parent
da5f59a996
commit
162651821e
1 changed files with 5 additions and 0 deletions
|
@ -227,6 +227,11 @@ public class SmackIntegrationTestFramework {
|
||||||
try {
|
try {
|
||||||
runTests(classes);
|
runTests(classes);
|
||||||
}
|
}
|
||||||
|
catch (Throwable t) {
|
||||||
|
// Log the thrown Throwable to prevent it being shadowed in case the finally block below also throws.
|
||||||
|
LOGGER.log(Level.SEVERE, "Unexpected abort because runTests() threw throwable", t);
|
||||||
|
throw t;
|
||||||
|
}
|
||||||
finally {
|
finally {
|
||||||
// Ensure that the accounts are deleted and disconnected before we continue
|
// Ensure that the accounts are deleted and disconnected before we continue
|
||||||
connectionManager.disconnectAndCleanup();
|
connectionManager.disconnectAndCleanup();
|
||||||
|
|
Loading…
Reference in a new issue