p2p/simulations: revert Simulation.Run from master

https://github.com/ethersphere/go-ethereum/pull/1077/files#r247078904
This commit is contained in:
Janos Guljas 2019-01-11 14:08:29 +01:00 committed by Elad Nachmias
parent a40801dead
commit 621e2b64ee

View file

@ -49,12 +49,10 @@ func (s *Simulation) Run(ctx context.Context, step *Step) (result *StepResult) {
defer stop() defer stop()
// perform the action // perform the action
if step.Action != nil {
if err := step.Action(ctx); err != nil { if err := step.Action(ctx); err != nil {
result.Error = err result.Error = err
return return
} }
}
// wait for all node expectations to either pass, error or timeout // wait for all node expectations to either pass, error or timeout
nodes := make(map[enode.ID]struct{}, len(step.Expect.Nodes)) nodes := make(map[enode.ID]struct{}, len(step.Expect.Nodes))