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

R4R: Redelegation doesn't subtract from liquid #1660

Merged
merged 5 commits into from
Jul 12, 2018
Merged

Conversation

rigelrozanski
Copy link
Contributor

closes #1630

  • Updated all relevant documentation in docs
  • Updated all code comments where relevant
  • Wrote tests
  • Updated CHANGELOG.md
  • Updated Gaia/Examples
  • Squashed all commits, uses message "Merge pull request #XYZ: [title]" (coding standards)
  • Added appropriate labels to PR (ex. wip, ready-for-review, docs)

@codecov
Copy link

codecov bot commented Jul 12, 2018

Codecov Report

❗ No coverage uploaded for pull request base (master@98bc419). Click here to learn what that means.
The diff coverage is 22.22%.

@@            Coverage Diff            @@
##             master    #1660   +/-   ##
=========================================
  Coverage          ?   63.61%           
=========================================
  Files             ?      122           
  Lines             ?     6805           
  Branches          ?        0           
=========================================
  Hits              ?     4329           
  Misses            ?     2230           
  Partials          ?      246

@cwgoes cwgoes force-pushed the rigel/redelegation-fix branch from 50e0fee to b88fb7c Compare July 12, 2018 23:18
Copy link
Contributor

@cwgoes cwgoes left a comment

Choose a reason for hiding this comment

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

Tested ACK

@cwgoes cwgoes merged commit 2885ac5 into master Jul 12, 2018
@cwgoes cwgoes deleted the rigel/redelegation-fix branch July 12, 2018 23:38
msgDelegate := newTestMsgDelegate(delegatorAddr, validatorAddr, initBond)
got = handleMsgDelegate(ctx, msgDelegate, keeper)
require.True(t, got.IsOK(), "expected delegation to be ok, got %v", got)

// balance should have been subtracted after delegation
amt2 := accMapper.GetAccount(ctx, delegatorAddr).GetCoins().AmountOf(denom)
require.Equal(t, amt1.Sub(sdk.NewInt(initBond)).Int64(), amt2.Int64(), "expected coins to be subtracted")
Copy link
Contributor Author

Choose a reason for hiding this comment

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

oh yeah, makes sense 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants