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

test(perp): Fix and refactor perp position cli tests #543

Merged
merged 1 commit into from
Jun 6, 2022

Conversation

NibiruHeisenberg
Copy link
Contributor

@NibiruHeisenberg NibiruHeisenberg commented Jun 6, 2022

  • fixed an assertion comparing sdk.AccAddress with string
  • prefer Assert() over Require() since Assert() doesn't stop the test and allows other assertions to run
  • prefer EqualValues() over Equal() because EqualValues() does not care about pointer equality
  • prefer NewDec() over MustNewDecFromStr() where possible because it allows you to underscore numerics, e.g. sdk.NewDec(1_000_000)

@NibiruHeisenberg NibiruHeisenberg requested a review from a team as a code owner June 6, 2022 00:08
@NibiruHeisenberg NibiruHeisenberg self-assigned this Jun 6, 2022
@NibiruHeisenberg NibiruHeisenberg added CLI type: tests Unit and integration test additions and improvements labels Jun 6, 2022
@NibiruHeisenberg NibiruHeisenberg changed the title test(perp): Fix perp position cli tests test(perp): Fix and refactor perp position cli tests Jun 6, 2022
@NibiruHeisenberg NibiruHeisenberg merged commit a963998 into master Jun 6, 2022
@NibiruHeisenberg NibiruHeisenberg deleted the fix/perp/position-cli-tests branch June 6, 2022 00:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: tests Unit and integration test additions and improvements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants