e23: fix generation by considering evidence age in retain height (#9306)

This commit is contained in:
Callum Waters
2022-08-23 11:28:32 +02:00
committed by GitHub
parent 50b5c23d88
commit 5f932a53f0
+9 -3
View File
@@ -34,9 +34,14 @@ var (
nodeMempools = uniformChoice{"v0", "v1"}
nodePersistIntervals = uniformChoice{0, 1, 5}
nodeSnapshotIntervals = uniformChoice{0, 3}
nodeRetainBlocks = uniformChoice{0, 1, 5}
abciDelays = uniformChoice{"none", "small", "large"}
nodePerturbations = probSetChoice{
nodeRetainBlocks = uniformChoice{
0,
2 * int(e2e.EvidenceAgeHeight),
4 * int(e2e.EvidenceAgeHeight),
}
evidence = uniformChoice{0, 1, 10}
abciDelays = uniformChoice{"none", "small", "large"}
nodePerturbations = probSetChoice{
"disconnect": 0.1,
"pause": 0.1,
"kill": 0.1,
@@ -66,6 +71,7 @@ func generateTestnet(r *rand.Rand, opt map[string]interface{}) (e2e.Manifest, er
InitialState: opt["initialState"].(map[string]string),
Validators: &map[string]int64{},
ValidatorUpdates: map[string]map[string]int64{},
Evidence: evidence.Choose(r).(int),
Nodes: map[string]*e2e.ManifestNode{},
}