1
0
mirror of https://github.com/moby/moby.git synced 2025-10-24 09:13:09 +03:00

all: replace loop with single append

Signed-off-by: Elena Morozova <lelenanam@gmail.com>
This commit is contained in:
Elena Morozova
2016-10-13 09:34:19 -07:00
parent 535f52c932
commit 64238fef8c
11 changed files with 15 additions and 45 deletions

View File

@@ -288,9 +288,7 @@ func (s *DockerSuite) TestNetworkLsFormat(c *check.C) {
expected := []string{"bridge", "host", "none"}
var names []string
for _, l := range lines {
names = append(names, l)
}
names = append(names, lines...)
c.Assert(expected, checker.DeepEquals, names, check.Commentf("Expected array with truncated names: %v, got: %v", expected, names))
}
@@ -312,9 +310,7 @@ func (s *DockerSuite) TestNetworkLsFormatDefaultFormat(c *check.C) {
expected := []string{"bridge default", "host default", "none default"}
var names []string
for _, l := range lines {
names = append(names, l)
}
names = append(names, lines...)
c.Assert(expected, checker.DeepEquals, names, check.Commentf("Expected array with truncated names: %v, got: %v", expected, names))
}