|
@@ -35,7 +35,11 @@ func (s *DockerSuite) TestImportBadURL(c *check.C) {
|
|
testRequires(c, DaemonIsLinux)
|
|
testRequires(c, DaemonIsLinux)
|
|
out, _, err := dockerCmdWithError("import", "http://nourl/bad")
|
|
out, _, err := dockerCmdWithError("import", "http://nourl/bad")
|
|
c.Assert(err, checker.NotNil, check.Commentf("import was supposed to fail but didn't"))
|
|
c.Assert(err, checker.NotNil, check.Commentf("import was supposed to fail but didn't"))
|
|
- c.Assert(out, checker.Contains, "dial tcp", check.Commentf("expected an error msg but didn't get one"))
|
|
|
|
|
|
+ // Depending on your system you can get either of these errors
|
|
|
|
+ if !strings.Contains(out, "dial tcp") &&
|
|
|
|
+ !strings.Contains(out, "Error processing tar file") {
|
|
|
|
+ c.Fatalf("expected an error msg but didn't get one.\nErr: %v\nOut: %v", err, out)
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
|
|
func (s *DockerSuite) TestImportFile(c *check.C) {
|
|
func (s *DockerSuite) TestImportFile(c *check.C) {
|