Skip to content
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

BSIP87 Tests #2172

Merged
merged 21 commits into from
May 12, 2020
Merged

BSIP87 Tests #2172

merged 21 commits into from
May 12, 2020

Conversation

christophersanborn
Copy link
Member

Unit tests followup to #2151.

@abitmore
Copy link
Member

abitmore commented May 9, 2020

There are commits

  • Improve error message in asset_claim_fees_evaluator
  • Revert "Improve error message in asset_claim_fees_evaluator"

Please rebase and remove these commits from the history.

Thanks.

@abitmore
Copy link
Member

abitmore commented May 9, 2020

OK, I changed my mind. The 2 commits are quite small, but it might need quite some efforts to remove them, I think it's fine to keep them, although generally it's not perfect.

tests/tests/bitasset_tests.cpp Outdated Show resolved Hide resolved
tests/tests/bitasset_tests.cpp Show resolved Hide resolved
tests/tests/bitasset_tests.cpp Outdated Show resolved Hide resolved
tests/tests/bitasset_tests.cpp Show resolved Hide resolved
tests/tests/bitasset_tests.cpp Show resolved Hide resolved
tests/tests/bitasset_tests.cpp Outdated Show resolved Hide resolved
tests/tests/bitasset_tests.cpp Show resolved Hide resolved
const string &name,
account_id_type issuer /* = GRAPHENE_WITNESS_ACCOUNT */,
uint16_t force_settlement_offset_percent /* 100 = 1% */,
optional<uint16_t> force_settlement_fee_percent /* 100 = 1% */
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ideally, we define a default value for this argument, then the function above with one argument fewer can be removed. Current code is acceptable for test cases though.

BTW I think it's better to add new parameters to the functions in database_fixture class, rather than adding new functions here. It's not a priority though, we can refactor in the future.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Those are reasonable points. We'll defer the refactoring for now.

tests/tests/force_settle_fee_tests.cpp Outdated Show resolved Hide resolved
tests/tests/force_settle_fee_tests.cpp Show resolved Hide resolved
tests/tests/force_settle_fee_tests.cpp Outdated Show resolved Hide resolved
tests/tests/bitasset_tests.cpp Show resolved Hide resolved
tests/tests/force_settle_fee_tests.cpp Outdated Show resolved Hide resolved
@MichelSantos
Copy link
Contributor

Thanks for the helpful review @abitmore. Hopefully the revisions address all of your comments.

@christophersanborn
Copy link
Member Author

@abitmore — I still have one open question here as to whether there is merit in rejecting an operation from do_evaluate() if force_settle_fee_parameter is unset in the operation but is set to a non-zero value in the asset object.

Copy link
Member

@abitmore abitmore left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks.

@abitmore abitmore merged commit 2fa51be into bitshares:hardfork May 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants