// Wait will wait for 2 seconds for the runner to stop
// otherwise it returns an error
Wait will wait for 2 seconds for the runner to stop
otherwise it returns an error
// Wait will wait for 2 seconds for the runner to stop // otherwise it returns an error
func (r *Runner) Wait() (err error) {
	select {
	case <-r.stopped:
		return nil
	case <-time.After(2 * time.Second):
		return errors.New("Failed to close in time")
	}
}
func ( r * Runner ) Wait ( ) ( err error ) { select { case <- r . stopped : return nil case <- time . After ( 2 * time . Second ) : return errors . New ( " " ) } }
Wait will wait for 2 seconds for the runner to stop
otherwise it returns an error
Wait will wait for 2 seconds for the runner to stop otherwise it returns an error