Skip to content

Commit

Permalink
Merge pull request #2169 from sunyuan3/curltimeout
Browse files Browse the repository at this point in the history
add timeout for curl to prevent from hanging
  • Loading branch information
allencloud authored Aug 29, 2018
2 parents 258ea08 + c6ac09d commit 199ad23
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/cli_network_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@ func (suite *PouchNetworkSuite) TestNetworkPortMapping(c *check.C) {
image).Assert(c, icmd.Success)

time.Sleep(10 * time.Second)
err := icmd.RunCommand("curl", "localhost:9999").Compare(expct)
err := icmd.RunCommand("timeout", "5", "curl", "localhost:9999").Compare(expct)
c.Assert(err, check.IsNil)

command.PouchRun("rm", "-f", funcname)
Expand Down

0 comments on commit 199ad23

Please sign in to comment.