les: remove invalid use of t.Fatal in TestHandshake (#21012)
This commit is contained in:
parent
7e4d1925f0
commit
c43be6cf87
@ -18,6 +18,7 @@ package les
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"crypto/rand"
|
"crypto/rand"
|
||||||
|
"errors"
|
||||||
"math/big"
|
"math/big"
|
||||||
"reflect"
|
"reflect"
|
||||||
"sort"
|
"sort"
|
||||||
@ -121,10 +122,10 @@ func TestHandshake(t *testing.T) {
|
|||||||
var reqType uint64
|
var reqType uint64
|
||||||
err := recv.get("announceType", &reqType)
|
err := recv.get("announceType", &reqType)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Fatal(err)
|
return err
|
||||||
}
|
}
|
||||||
if reqType != announceTypeSigned {
|
if reqType != announceTypeSigned {
|
||||||
t.Fatal("Expected announceTypeSigned")
|
return errors.New("Expected announceTypeSigned")
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user