plaster
plaster copied to clipboard
Make flake8-bugbear happy
flake8-bugbear declares:
B017 'assertRaises(Exception)' and 'pytest.raises(Exception)' should be considered evil.
This eliminates the complaint.
Again, it is unclear what the best match re is, or the more specific exception trap is.
The last hunk (match="BadLoader") produces the exception:
<ExceptionInfo AttributeError("'BadLoader' object has no attribute 'setup_logging'") tblen=3>
The earlier 3 hunks produce exceptions that rep like (differing only in the scheme reported):
<ExceptionInfo LoaderNotFound('Could not find a matching loader for the scheme "file+bad".') tblen=4>
I believe that match re-s given are a good representation of the expected error,s but I did the obvious thing and didn't think too deeply.