-
Notifications
You must be signed in to change notification settings - Fork 9
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
fix: delete unnecessary test #43
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a test doing as same as the test at Finschia/finschia-sdk@bde56b9 in x/wasmplus?
I'll check. |
This test do almost the same thing. wasmd/x/wasmplus/keeper/keeper_test.go Lines 37 to 55 in 74de5b2
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is my understanding below correct?
The intent of the test is to execute an inactive contract and return an error, but the function UpdateContractStatus()
which was used in that case, has been eliminated. In addition, the test to confirm the execution of an inactive contract and the return of an error is performed by TestDeactivateContract. Therefore, the TestExecuteManualInactiveContractFailure() should be removed.
@kokeshiM0chi |
It looks not the same test. As bellow, the test you delete checks other ways than gov proposal cannot change the contract state. Finschia/finschia-sdk@bde56b9#diff-591082558a25fcf8aa75120ea3d175720c0293fbde4bdf526ee60b491466a570L823-L827 |
I understand that So I am thinking that the role of the test I said is the same. |
I don't know because I cannot judge whether
means the authorization to active/inactive contracts is not within the scope of x/wasmplus or not. We should confirm what part checks the authorization first. In any case, there should be some tests checking authorization to active/inactive contracts works. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please, update changelog.
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #43 +/- ##
==========================================
- Coverage 60.83% 60.79% -0.04%
==========================================
Files 80 80
Lines 9879 9877 -2
==========================================
- Hits 6010 6005 -5
- Misses 3553 3555 +2
- Partials 316 317 +1
|
Added. |
As confirmed by #48, active/inactive management is done by wasmplus. wasmd/x/wasmplus/keeper/contract_keeper.go Lines 15 to 16 in ff18c54
In the test I deleted, "contract status", which was checked by And when you use |
…#53) * build: replace line repositories with finschia repositories (#30) * build: replace line repositories with finschia repositories * Update x/wasmplus/README.md Co-authored-by: zemyblue <zemyblue@gmail.com> * Update x/wasm/ibc_reflect_test.go Co-authored-by: zemyblue <zemyblue@gmail.com> * Update .github/dependabot.yml Co-authored-by: jaeseung-bae <119839167+jaeseung-bae@users.noreply.github.com> * Update CHANGELOG.md Co-authored-by: jaeseung-bae <119839167+jaeseung-bae@users.noreply.github.com> * Update CHANGELOG.md Co-authored-by: jaeseung-bae <119839167+jaeseung-bae@users.noreply.github.com> * docs: replace a comment contains line with finschia one * build: replace line in Dockerfile with finschia * docs: replace line in README.md with Finschia * docs: update CHANGELOG --------- Co-authored-by: zemyblue <zemyblue@gmail.com> Co-authored-by: jaeseung-bae <119839167+jaeseung-bae@users.noreply.github.com> * chore: update changelog for release v0.1.3 (#31) * fix: stop wrap twice the response of handling non-plus wasm message in plus handler (#35) * fix: stop wrap twice non-plus wasm hander's response fix #33 * test: add tests handling non-plus wasm messages * docs: add this PR to CHANGELOG.md * fix: reflect golangci-lint * fix: simplify how to handle the message in wasmplus * chore: update notice (#44) * chore: update notice * chore: update changelog * fix: delete unnecessary test (#43) * fix: delete unnecessary test * docs: add CHANGELOG * feat: add admin-related events (#46) * add admin-related events in docs * fix ClearAdmin event * cherry-pick upstream admin-related events update * chore: update changelog for release v0.1.4 (#49) * build: update depending wasmvm to v1.1.1-0.11.2-dynamiclink2 and update tests --------- Co-authored-by: zemyblue <zemyblue@gmail.com> Co-authored-by: jaeseung-bae <119839167+jaeseung-bae@users.noreply.github.com> Co-authored-by: Daisuke Iuchi <42408108+da1suk8@users.noreply.github.com> Co-authored-by: Jayden Lee <41176085+tkxkd0159@users.noreply.github.com>
Description
closes: #39
This test was moved from finschia-sdk by #1 and added by Finschia/finschia-sdk#470.
Previously, a function called
UpdateContractStatus()
was used in Finschia/finschia-sdk@bde56b9,but it was removed from wasmd and has become a meaningless test.
Further checking with #48, active/inactive management is done by wasmplus.
wasmd/x/wasmplus/keeper/contract_keeper.go
Lines 15 to 16 in ff18c54
In the test I deleted, "contract status", which was checked by
UpdateContractStatus()
, is not used in the current wasmd, so there is no problem in deleting it.And when you use
UpdateContractStatus()
before, you could only change it via gov proposal, which was tested, but is no longer necessary.So I think it is better to remove this test.
Motivation and context
I don't want to leave a meaningless test.
Checklist:
CHANGELOG.md
client/docs/swagger-ui/swagger.yaml