Browse code

Fixed error check using the wrong error value

errorOut was using the err from the previous test.
same as #7816 but on TestTopPrivileged, which I missed last time

Signed-off-by: Frank Rosquin <frank.rosquin@gmail.com>

Frank Rosquin authored on 2014/08/31 23:35:38
Showing 1 changed files
... ...
@@ -52,7 +52,7 @@ func TestTopPrivileged(t *testing.T) {
52 52
 
53 53
 	topCmd = exec.Command(dockerBinary, "top", cleanedContainerID)
54 54
 	out2, _, err2 := runCommandWithOutput(topCmd)
55
-	errorOut(err, t, fmt.Sprintf("failed to run top: %v %v", out2, err2))
55
+	errorOut(err2, t, fmt.Sprintf("failed to run top: %v %v", out2, err2))
56 56
 
57 57
 	killCmd := exec.Command(dockerBinary, "kill", cleanedContainerID)
58 58
 	_, err = runCommand(killCmd)