Browse Source

testutil/daemon: remove redundant d.cmd.Wait()

`daemon.StartWithLogFile()` already creates a goroutine that
calls `d.cmd.Waits()` and sends its return to the channel, `d.Wait`.

This code called `d.cmd.Wait()` one more time, and returns the
error, which may produce an error _because_ it's called a second
time, and potentially cause an incorrect test-result.

(thanks to Kir Kolyshkin for spotting this)

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Sebastiaan van Stijn 5 years ago
parent
commit
293c1a27a2
1 changed files with 1 additions and 1 deletions
  1. 1 1
      testutil/daemon/daemon.go

+ 1 - 1
testutil/daemon/daemon.go

@@ -524,7 +524,7 @@ out2:
 		return err
 	}
 
-	return d.cmd.Wait()
+	return nil
 }
 
 // Restart will restart the daemon by first stopping it and the starting it.