Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Jayashsatolia403 committed Aug 17, 2023
1 parent 56f838a commit a4d9ec3
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions tests/tokenomics_tests/allocation_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ func TestAllocationRewards(testSetup *testing.T) {

t.TestSetup("set storage config to use time_unit as 5 minutes", func() {
output, err := utils.UpdateStorageSCConfig(t, scOwnerWallet, map[string]string{
"time_unit": "5m",
"time_unit": "10m",
}, true)
require.Nil(t, err, strings.Join(output, "\n"))
})
Expand Down Expand Up @@ -222,7 +222,7 @@ func TestAllocationRewards(testSetup *testing.T) {
require.Nil(t, err)

// sleep for 5 minutes
time.Sleep(8 * time.Minute)
time.Sleep(15 * time.Minute)

alloc = utils.GetAllocation(t, allocationId)
require.Equal(t, movedToChallengePool, alloc.MovedToChallenge, "MovedToChallenge should not change")
Expand Down Expand Up @@ -286,10 +286,10 @@ func TestAllocationRewards(testSetup *testing.T) {
_, err := utils.ExecuteFaucetWithTokensForWallet(t, "wallets/blobber_owner", configPath, 99)
require.Nil(t, err, "Error executing faucet", strings.Join(output, "\n"))

output, err = utils.UpdateBlobberInfoForWallet(t, configPath, "wallets/blobber_owner", utils.CreateParams(map[string]interface{}{"blobber_id": intialBlobberInfo.ID, "read_price": utils.IntToZCN(intialBlobberInfo.Terms.ReadPrice + 1e9)}))
output, err = utils.UpdateBlobberInfoForWallet(t, configPath, "wallets/blobber_owner", utils.CreateParams(map[string]interface{}{"blobber_id": intialBlobberInfo.ID, "read_price": utils.IntToZCN(intialBlobberInfo.Terms.ReadPrice * 10)}))
require.Nil(t, err, strings.Join(output, "\n"))

output, err = utils.UpdateBlobberInfoForWallet(t, configPath, "wallets/blobber_owner", utils.CreateParams(map[string]interface{}{"blobber_id": intialBlobberInfo.ID, "write_price": utils.IntToZCN(intialBlobberInfo.Terms.WritePrice + 1e9)}))
output, err = utils.UpdateBlobberInfoForWallet(t, configPath, "wallets/blobber_owner", utils.CreateParams(map[string]interface{}{"blobber_id": intialBlobberInfo.ID, "write_price": utils.IntToZCN(intialBlobberInfo.Terms.WritePrice * 10)}))
require.Nil(t, err, strings.Join(output, "\n"))
}

Expand All @@ -303,7 +303,7 @@ func TestAllocationRewards(testSetup *testing.T) {
require.Greater(t, alloc.MovedToChallenge, movedToChallengePool, "MovedToChallenge should not change")

// sleep for 5 minutes
time.Sleep(5 * time.Minute)
time.Sleep(15 * time.Minute)

rewards := getTotalAllocationChallengeRewards(t, allocationId)

Expand Down

0 comments on commit a4d9ec3

Please sign in to comment.