-
Notifications
You must be signed in to change notification settings - Fork 123
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
Coverage test: coins tests #613
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.
Few comments, otherwise code is good.
x/pylons/keeper/coins_test.go
Outdated
@@ -47,3 +47,126 @@ func (suite *IntegrationTestSuite) TestMintCoinsToAddr() { | |||
balance := bk.SpendableCoins(ctx, addr) | |||
require.True(balance.IsEqual(mintAmt)) | |||
} | |||
|
|||
func (suite *IntegrationTestSuite) TestBurnCoins() { | |||
// k, ctx := setupKeeper(t) |
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.
Can we remove dead code?
x/pylons/keeper/coins_test.go
Outdated
} | ||
|
||
func (suite *IntegrationTestSuite) TestBurnCoinsFromAddress() { | ||
// k, ctx := setupKeeper(t) |
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.
This dead code as well
x/pylons/keeper/coins_test.go
Outdated
} | ||
|
||
func (suite *IntegrationTestSuite) TestMintCreditToAddr() { | ||
// k, ctx := setupKeeper(t) |
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.
This dead code can be removed as well
x/pylons/keeper/coins_test.go
Outdated
} | ||
|
||
func (suite *IntegrationTestSuite) TestSendRewardsFromFeeCollector() { | ||
// k, ctx := setupKeeper(t) |
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.
This dead code can be removed as well.
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.
Thanks
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.
One more typo, otherwise it's good.
x/pylons/keeper/coins_test.go
Outdated
err := k.MintCoins(ctx, types.PaymentsProcessorName, mintAmt) | ||
require.NoError(err) | ||
|
||
// PaymentsProcessor account has buner permissions |
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.
"PaymentsProcessor account has burner permissions" would be the right comment.
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.
my mistake 😭
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.
Looks good to me now.
This Pr is to add the test case in issue #497.
Now coins tests available, I'll write more test for another tasks