Skip to content

Commit

Permalink
update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
matijamarjanovic committed Feb 20, 2025
1 parent 2e4e782 commit e14bb80
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -185,19 +185,19 @@ func TestCreateCoinToTokenTicket(t *testing.T) {
}

{
std.TestSetOrigSend(std.Coins{{"wrongcoin", 1000}}, nil)
std.TestSetOriginSend(std.Coins{{"wrongcoin", 1000}}, nil)
_, err := CreateCoinToTokenTicket("ugnot", "gno.land/r/test/tickets.test_token", 1000, 24)
uassert.Error(t, err, "Should fail with wrong coin denomination")
}

{
std.TestSetOrigSend(std.Coins{{"ugnot", 1000}, {"other", 500}}, nil)
std.TestSetOriginSend(std.Coins{{"ugnot", 1000}, {"other", 500}}, nil)
_, err := CreateCoinToTokenTicket("ugnot", "gno.land/r/test/tickets.test_token", 1000, 24)
uassert.Error(t, err, "Should fail with multiple coins")
}

{
std.TestSetOrigSend(std.Coins{{"ugnot", 1000}}, nil)
std.TestSetOriginSend(std.Coins{{"ugnot", 1000}}, nil)
ticketID, err := CreateCoinToTokenTicket("ugnot", "gno.land/r/test/tickets.test_token", 1000, 24)
urequire.NoError(t, err, "Should create ticket successfully")
uassert.NotEmpty(t, ticketID, "Ticket ID should not be empty")
Expand Down

0 comments on commit e14bb80

Please sign in to comment.