-
Notifications
You must be signed in to change notification settings - Fork 338
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Regression Tests are not valid until we check for specific exceptions #113
Comments
Related: #117 |
Here is my proposal for an exception hierarchy:
Compile-time template automagic will be used to enforce the correct value Currently the following values of
|
Note, many operations throw This is actually a feature, not a flaw. If the primary purpose of exceptions is to allow the testing framework to confirm that a specific assert exception triggers under the conditions set up by the test, then it makes sense to have each exception type thrown by a very small number of places in the code -- ideally in only one place. This makes each test able to confirm with high specificity that the observed exception does in fact indicate the desired assertion has failed, and not some other assertion. |
If it is desired to have a general It seems hard to figure out an actual use case which would actually want to catch the base class, however -- which suggests this feature need not be implemented. |
This issue was moved to bitshares/bitshares-core#32 |
Right now a test checking for an exception will pass regardless of what type of error actually occurred. For the tests to be valid every exception that we test for needs to be explicit.
The text was updated successfully, but these errors were encountered: