mirror of
https://github.com/tendermint/tendermint.git
synced 2026-08-28 03:46:33 +00:00
p2p: extend e2e tests for new p2p framework (#6323)
This commit is contained in:
@@ -58,6 +58,13 @@ type Manifest struct {
|
||||
// LogLevel sets the log level of the entire testnet. This can be overridden
|
||||
// by individual nodes.
|
||||
LogLevel string `toml:"log_level"`
|
||||
|
||||
// UseNewP2P enables use of the new p2p layer for all nodes in
|
||||
// a test.
|
||||
UseNewP2P bool `toml:"use_new_p2p"`
|
||||
|
||||
// QueueType describes the type of queue that the system uses internally
|
||||
QueueType string `toml:"queue_type"`
|
||||
}
|
||||
|
||||
// ManifestNode represents a node in a testnet manifest.
|
||||
@@ -134,6 +141,13 @@ type ManifestNode struct {
|
||||
// This is helpful when debugging a specific problem. This overrides the network
|
||||
// level.
|
||||
LogLevel string `toml:"log_level"`
|
||||
|
||||
// UseNewP2P enables use of the new p2p layer for this node.
|
||||
UseNewP2P bool `toml:"use_new_p2p"`
|
||||
|
||||
// QueueType describes the type of queue that the p2p layer
|
||||
// uses internally.
|
||||
QueueType string `toml:"queue_type"`
|
||||
}
|
||||
|
||||
// Save saves the testnet manifest to a file.
|
||||
|
||||
@@ -90,6 +90,8 @@ type Node struct {
|
||||
PersistentPeers []*Node
|
||||
Perturbations []Perturbation
|
||||
LogLevel string
|
||||
UseNewP2P bool
|
||||
QueueType string
|
||||
}
|
||||
|
||||
// LoadTestnet loads a testnet from a manifest file, using the filename to
|
||||
@@ -167,6 +169,8 @@ func LoadTestnet(file string) (*Testnet, error) {
|
||||
RetainBlocks: nodeManifest.RetainBlocks,
|
||||
Perturbations: []Perturbation{},
|
||||
LogLevel: manifest.LogLevel,
|
||||
UseNewP2P: manifest.UseNewP2P,
|
||||
QueueType: manifest.QueueType,
|
||||
}
|
||||
if node.StartAt == testnet.InitialHeight {
|
||||
node.StartAt = 0 // normalize to 0 for initial nodes, since code expects this
|
||||
|
||||
Reference in New Issue
Block a user