Signed-off-by: Tibor Vass <tibor@docker.com>
(cherry picked from commit 318b1612e1a74f1313d5bd087050cd535f267bd5)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
| ... | ... |
@@ -24,7 +24,6 @@ import ( |
| 24 | 24 |
"time" |
| 25 | 25 |
|
| 26 | 26 |
"github.com/docker/docker/client" |
| 27 |
- "github.com/docker/docker/integration-cli/checker" |
|
| 28 | 27 |
"github.com/docker/docker/integration-cli/cli" |
| 29 | 28 |
"github.com/docker/docker/integration-cli/cli/build" |
| 30 | 29 |
"github.com/docker/docker/internal/test/fakecontext" |
| ... | ... |
@@ -3952,7 +3951,7 @@ func (s *DockerSuite) TestRunAttachFailedNoLeak(c *testing.T) {
|
| 3952 | 3952 |
strings.Contains(string(out), "were not connected because a duplicate name exists") || |
| 3953 | 3953 |
strings.Contains(string(out), "The specified port already exists") || |
| 3954 | 3954 |
strings.Contains(string(out), "HNS failed with error : Failed to create endpoint") || |
| 3955 |
- strings.Contains(string(out), "HNS failed with error : The object already exists"), checker.Equals, true, fmt.Sprintf("Output: %s", out))
|
|
| 3955 |
+ strings.Contains(string(out), "HNS failed with error : The object already exists"), fmt.Sprintf("Output: %s", out))
|
|
| 3956 | 3956 |
dockerCmd(c, "rm", "-f", "test") |
| 3957 | 3957 |
|
| 3958 | 3958 |
// NGoroutines is not updated right away, so we need to wait before failing |
| ... | ... |
@@ -430,8 +430,8 @@ func waitAndAssert(t assert.TestingT, timeout time.Duration, f checkF, compariso |
| 430 | 430 |
default: |
| 431 | 431 |
} |
| 432 | 432 |
if shouldAssert {
|
| 433 |
- if comment != nil {
|
|
| 434 |
- args = append(args, comment.CheckCommentString()) |
|
| 433 |
+ if len(comment) > 0 {
|
|
| 434 |
+ args = append(args, comment) |
|
| 435 | 435 |
} |
| 436 | 436 |
assert.Assert(t, comparison, args...) |
| 437 | 437 |
return |
| ... | ... |
@@ -450,8 +450,8 @@ func reducedCheck(r reducer, funcs ...checkF) checkF {
|
| 450 | 450 |
for _, f := range funcs {
|
| 451 | 451 |
v, comment := f(c) |
| 452 | 452 |
values = append(values, v) |
| 453 |
- if comment != nil {
|
|
| 454 |
- comments = append(comments, comment.CheckCommentString()) |
|
| 453 |
+ if len(comment) > 0 {
|
|
| 454 |
+ comments = append(comments, comment) |
|
| 455 | 455 |
} |
| 456 | 456 |
} |
| 457 | 457 |
return r(values...), fmt.Sprintf("%v", strings.Join(comments, ", "))
|