Skip to content

Commit

Permalink
fix: test: correctly check error in window post test
Browse files Browse the repository at this point in the history
  • Loading branch information
Stebalien committed May 23, 2022
1 parent e717d51 commit 4be964a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions itests/wdpost_dispute_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,8 @@ func TestWindowPostDispute(t *testing.T) {
// Now try to be evil again
err = submitBadProof(ctx, client, evilMiner.OwnerKey.Address, evilMinerAddr, di, evilSectorLoc.Deadline, evilSectorLoc.Partition)
require.Error(t, err)
require.Equal(t, 16, err)
require.Contains(t, err.Error(), "window post failed: invalid PoSt")
require.Contains(t, err.Error(), "(RetCode=16)")

// It didn't work because we're recovering.
}
Expand Down Expand Up @@ -330,7 +331,8 @@ waitForProof:
}
_, err := client.MpoolPushMessage(ctx, msg, nil)
require.Error(t, err)
require.Equal(t, err, 16)
require.Contains(t, err.Error(), "failed to dispute valid post")
require.Contains(t, err.Error(), "(RetCode=16)")
}
}

Expand Down

0 comments on commit 4be964a

Please # to comment.