diff options
author | Sebastiaan van Stijn <github@gone.nl> | 2017-01-18 03:08:31 +0100 |
---|---|---|
committer | Sebastiaan van Stijn <github@gone.nl> | 2017-01-24 11:16:19 +0100 |
commit | ba0afd70e89562aa3c668c87fb9191ed9edb7260 (patch) | |
tree | 3897d6cd2463d256e3e7e11d2ddfa204b7f932ec /pkg/ioutils | |
parent | 8820266c17beede7d08b6b077383978f3b7b239f (diff) | |
download | docker-ba0afd70e89562aa3c668c87fb9191ed9edb7260.tar.gz |
fix some ineffectual assignments
to make goreportcard a bit happier
https://goreportcard.com/report/github.com/docker/docker
also found that `TestCpToErrDstParentNotExists()` was
partially broken, because a `runDockerCp()` was inadvertently
removed in f26a31e80cfcc77daba0872ddb14bf03f4398311
`TestDaemonRestartSaveContainerExitCode()` didn't verify
the actual _Error_ message, so added that to the test,
and updated the test to take into account that the
"experimental" CI enables `--init` on containers.
`TestVolumeCLICreateOptionConflict()` only checked
for an error to occur, but didn't validate if the
error was due to conflicting options.
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Diffstat (limited to 'pkg/ioutils')
-rw-r--r-- | pkg/ioutils/buffer_test.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/pkg/ioutils/buffer_test.go b/pkg/ioutils/buffer_test.go index 41098fa6e7..8bf5ae64ea 100644 --- a/pkg/ioutils/buffer_test.go +++ b/pkg/ioutils/buffer_test.go @@ -21,6 +21,9 @@ func TestFixedBufferWrite(t *testing.T) { } n, err = buf.Write(bytes.Repeat([]byte{1}, 64)) + if n != 59 { + t.Fatalf("expected 59 bytes written before buffer is full, got %d", n) + } if err != errBufferFull { t.Fatalf("expected errBufferFull, got %v - %v", err, buf.buf[:64]) } |