Skip to content

Commit

Permalink
add missing error checks in retryable unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
magicxyyz committed Jul 11, 2023
1 parent fe76152 commit 8edc704
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions arbos/retryable_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,8 @@ func TestRetryableLifecycle(t *testing.T) {
Require(t, err)
expectedRetryableState := expectedArbosState.RetryableState()
for _, retryData := range retriesData {
expectedRetryableState.Expired.Append(retryData.Hash())
_, _, err := expectedRetryableState.Expired.Append(retryData.Hash())
Require(t, err)
}
if expectedState.IntermediateRoot(true) != statedb.IntermediateRoot(true) {
Fail(t, "unexpected state after reaping")
Expand Down Expand Up @@ -244,7 +245,8 @@ func TestRetryableCleanup(t *testing.T) {
expectedArbosState, err := arbosState.OpenSystemArbosState(expectedState, nil, false)
Require(t, err)
expectedRetryableState := expectedArbosState.RetryableState()
expectedRetryableState.Expired.Append(retryables.RetryableHash(id, 0, from, to, callValue, beneficiary, callData))
_, _, err = expectedRetryableState.Expired.Append(retryables.RetryableHash(id, 0, from, to, callValue, beneficiary, callData))
Require(t, err)
stateCheck(t, statedb, expectedState, false, "state has changed", func() {
_, err := retryableState.CreateRetryable(id, timeout, from, &to, callValue, beneficiary, callData)
Require(t, err)
Expand Down

0 comments on commit 8edc704

Please sign in to comment.