mongoaudit
mongoaudit copied to clipboard
Exception handling in tests is inconsistent.
I ran into this while debugging #9.
The connection exception, which gives valuable information, is silently swallowed in testers.py#Tester#get_connection. In contrast, tester exceptions themselves aren't caught at all and cause mongoaudit to crash.
Expected behavior: The connection exception is surfaced and testing does not continue If an exception is encountered in a particular test, it is logged and the rest of the tests continue as normal. This allows a user to see the results of the non-crashed tests.