cmd/devp2p/internal/ethtest: skip eth/66 tests when v66 not supported (#22460)
This commit is contained in:
@ -22,6 +22,7 @@ import (
|
||||
|
||||
"github.com/ethereum/go-ethereum/cmd/devp2p/internal/ethtest"
|
||||
"github.com/ethereum/go-ethereum/crypto"
|
||||
"github.com/ethereum/go-ethereum/internal/utesting"
|
||||
"github.com/ethereum/go-ethereum/p2p"
|
||||
"github.com/ethereum/go-ethereum/p2p/rlpx"
|
||||
"github.com/ethereum/go-ethereum/rlp"
|
||||
@ -98,5 +99,10 @@ func rlpxEthTest(ctx *cli.Context) error {
|
||||
if err != nil {
|
||||
exit(err)
|
||||
}
|
||||
return runTests(ctx, suite.EthTests())
|
||||
// check if given node supports eth66, and if so, run eth66 protocol tests as well
|
||||
is66Failed, _ := utesting.Run(utesting.Test{Name: "Is_66", Fn: suite.Is_66})
|
||||
if is66Failed {
|
||||
return runTests(ctx, suite.EthTests())
|
||||
}
|
||||
return runTests(ctx, suite.AllEthTests())
|
||||
}
|
||||
|
Reference in New Issue
Block a user