Use errdefs for handling errors in client

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn
2019-02-09 19:19:22 +01:00
parent 053c6f097a
commit 0cafc84fb2
7 changed files with 12 additions and 12 deletions

View File

@@ -121,6 +121,7 @@ func TestCopyToContainerNotFoundError(t *testing.T) {
}
}
// TODO TestCopyToContainerNotStatusOKError expects a non-error status-code ("204 No Content") to produce an error; verify if this is the desired behavior
func TestCopyToContainerNotStatusOKError(t *testing.T) {
client := &Client{
client: newMockClient(errorMock(http.StatusNoContent, "No content")),
@@ -200,6 +201,7 @@ func TestCopyFromContainerNotFoundError(t *testing.T) {
}
}
// TODO TestCopyFromContainerNotStatusOKError expects a non-error status-code ("204 No Content") to produce an error; verify if this is the desired behavior
func TestCopyFromContainerNotStatusOKError(t *testing.T) {
client := &Client{
client: newMockClient(errorMock(http.StatusNoContent, "No content")),