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
test: replace bare asserts with assertion helpers (assert_equal() etc.) #23119
Comments
|
I can take the lock on this issue? |
|
@vincenzopalazzo feel free to open a pull request :) |
|
Hi ! Can I take up this issue? |
|
Hey @vincenzopalazzo Thanks for replying and the reference. But can you elaborate a little on the same? This will be my first PR and I am looking to make a positive contribution. |
|
Hi @vincenzopalazzo, IMO the change of the same issue in different PR is very confusing for the people that will make a review, and also work in a different file. As discussed in this issue #23135 (review) I will make all the changes in one PR in the different commit, however some review of the works is very welcome. P.S: The PR will include also an additional method inside the test framework, to know more you can look inside #23127 |
|
I'm taking a look at this |
|
oh, now I see @vincenzopalazzo remarks. |
|
Is this issue still open? Could I help? |
Maybe with some PR review? |
|
Building on theStack's initial script, instead of focusing on the (in)equality operators which are also present in the test_framework's assert functions, I think it might be easier to just rely on the limited set of forms that Python's built in assert statement can come in. To my knowledge, this is either The below script should capture more problematic cases (e.g. this also includes boolean asserts) and exclude all of the false positives that arise when (in)equality operators are used in the test_framework assert functions. cd ./test/functional
git grep "assert\( *\)("
git grep "assert \( *\)"edit: |
#23117 replaced asserts with the test framework's internal helpers (see
bitcoin/test/functional/test_framework/util.py
Lines 47 to 59 in dccf3d2
Useful skills:
basic Python3 knowledge
Want to work on this issue?
For guidance on contributing, please read CONTRIBUTING.md before opening your pull request.
The text was updated successfully, but these errors were encountered: