Skip to content

Commit 1dd921e

Browse files
committed
fix compile error for reward03 test
1 parent b218fe8 commit 1dd921e

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

launchpad/tests/__TEST_launchpad_reward_and_gov_reward_03_test.gnoA

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@ import (
2727
sr "gno.land/r/gnoswap/v1/staker"
2828
)
2929

30+
//! TODO: may need to change deadline param in `ExactInSwapRoute` function
31+
3032
var (
3133
launchpadProject01Addr = testutils.TestAddress("launchpadProject01")
3234
launchpadProject01Realm = std.NewUserRealm(launchpadProject01Addr)
@@ -143,7 +145,7 @@ func testMint(t *testing.T) {
143145
func testStakeToken(t *testing.T) {
144146
t.Run("stake token", func(t *testing.T) {
145147
std.TestSetRealm(adminRealm)
146-
gnft.Approve(a2u(consts.STAKER_ADDR), "1")
148+
gnft.Approve(consts.STAKER_ADDR, "1")
147149

148150
sr.StakeToken(1)
149151

@@ -296,6 +298,7 @@ func testSwapRoute(t *testing.T) {
296298
"gno.land/r/onbloc/bar:gno.land/r/onbloc/foo:500",
297299
"100",
298300
"1",
301+
time.Now().Unix(),
299302
)
300303
uassert.Equal(t, amountIn, "100000")
301304
uassert.Equal(t, amountOut, "-99800")
@@ -321,6 +324,7 @@ func testSwapRoute(t *testing.T) {
321324
"gno.land/r/onbloc/baz:gno.land/r/onbloc/bar:500",
322325
"100",
323326
"1",
327+
time.Now().Unix(),
324328
)
325329
uassert.Equal(t, amountIn, "100000")
326330
uassert.Equal(t, amountOut, "-99800")
@@ -348,6 +352,7 @@ func testSwapRoute(t *testing.T) {
348352
"gno.land/r/gnoswap/v1/gns:gno.land/r/demo/wugnot:3000",
349353
"100",
350354
"1",
355+
time.Now().Unix(),
351356
)
352357
uassert.Equal(t, amountIn, "100000")
353358
uassert.Equal(t, amountOut, "-99550")
@@ -411,8 +416,7 @@ func testCheckReward(t *testing.T) {
411416

412417
func checkProtocolFeeBalance() {
413418
println("[START] checkProtocolFeeBalance")
414-
pfRegistered := pf.GetRegisteredTokens()
415-
for _, token := range pfRegistered {
419+
for _, token := range common.ListRegisteredTokens() {
416420
balance := common.BalanceOf(token, consts.PROTOCOL_FEE_ADDR)
417421
if balance != 0 {
418422
println("token", token)

0 commit comments

Comments
 (0)