mirror of
https://github.com/LBRYFoundation/lbcutil.git
synced 2025-08-23 17:47:30 +00:00
Fix OutOfRangeError checks in block_test.go
This commit is contained in:
parent
e3017c9aab
commit
c53e27f6f1
1 changed files with 2 additions and 2 deletions
|
@ -270,7 +270,7 @@ func TestBlockErrors(t *testing.T) {
|
|||
t.Errorf("TxHash: wrong error - got: %v <%T>, "+
|
||||
"want: <%T>", err, err, btcutil.OutOfRangeError(""))
|
||||
}
|
||||
_, err = b.TxHash(len(Block100000.Transactions) + 1)
|
||||
_, err = b.TxHash(len(Block100000.Transactions))
|
||||
if _, ok := err.(btcutil.OutOfRangeError); !ok {
|
||||
t.Errorf("TxHash: wrong error - got: %v <%T>, "+
|
||||
"want: <%T>", err, err, btcutil.OutOfRangeError(""))
|
||||
|
@ -282,7 +282,7 @@ func TestBlockErrors(t *testing.T) {
|
|||
t.Errorf("Tx: wrong error - got: %v <%T>, "+
|
||||
"want: <%T>", err, err, btcutil.OutOfRangeError(""))
|
||||
}
|
||||
_, err = b.Tx(len(Block100000.Transactions) + 1)
|
||||
_, err = b.Tx(len(Block100000.Transactions))
|
||||
if _, ok := err.(btcutil.OutOfRangeError); !ok {
|
||||
t.Errorf("Tx: wrong error - got: %v <%T>, "+
|
||||
"want: <%T>", err, err, btcutil.OutOfRangeError(""))
|
||||
|
|
Loading…
Add table
Reference in a new issue