<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/docker.git/integration/container/copy_test.go, branch master</title>
<subtitle>github.com: dotcloud/docker.git
</subtitle>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/docker.git/'/>
<entry>
<title>integration: update error-assertions in tests</title>
<updated>2023-05-10T20:13:50+00:00</updated>
<author>
<name>Sebastiaan van Stijn</name>
<email>github@gone.nl</email>
</author>
<published>2023-05-10T11:19:53+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/docker.git/commit/?id=56fb56ccf030746bcdcf9803df0f848c156a4592'/>
<id>56fb56ccf030746bcdcf9803df0f848c156a4592</id>
<content type='text'>
- use is.ErrorType
- replace uses of client.IsErrNotFound for errdefs.IsNotFound, as
  the client no longer returns the old error-type.

Signed-off-by: Sebastiaan van Stijn &lt;github@gone.nl&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- use is.ErrorType
- replace uses of client.IsErrNotFound for errdefs.IsNotFound, as
  the client no longer returns the old error-type.

Signed-off-by: Sebastiaan van Stijn &lt;github@gone.nl&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>integration: test more copy edge-cases</title>
<updated>2022-10-26T16:06:31+00:00</updated>
<author>
<name>Cory Snider</name>
<email>csnider@mirantis.com</email>
</author>
<published>2022-10-12T23:25:56+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/docker.git/commit/?id=7d23c505994cd07ca29dde3abb6d66f6c5d70cf0'/>
<id>7d23c505994cd07ca29dde3abb6d66f6c5d70cf0</id>
<content type='text'>
The existing archive implementation is not easy to reason about by
reading the source. Prepare to rewrite it by covering more edge cases in
tests. The new test cases were determined by black-box characterizing
the existing behaviour.

Signed-off-by: Cory Snider &lt;csnider@mirantis.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The existing archive implementation is not easy to reason about by
reading the source. Prepare to rewrite it by covering more edge cases in
tests. The new test cases were determined by black-box characterizing
the existing behaviour.

Signed-off-by: Cory Snider &lt;csnider@mirantis.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>client: CopyToContainer(), CopyFromContainer(): remove status-code handling</title>
<updated>2022-04-19T06:28:20+00:00</updated>
<author>
<name>Sebastiaan van Stijn</name>
<email>github@gone.nl</email>
</author>
<published>2022-03-20T16:13:04+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/docker.git/commit/?id=013d6488888d2362185b0738e9f600d4ba95d88a'/>
<id>013d6488888d2362185b0738e9f600d4ba95d88a</id>
<content type='text'>
This was added in 93c3e6c91ec5eb4202b86b44b011d06f5e048dab, at which time only
some basic handling of non-succesful status codes was present;
https://github.com/moby/moby/blob/93c3e6c91ec5eb4202b86b44b011d06f5e048dab/api/client/utils.go#L112-L121

Given that since 38e6d474affe08230043fa36fa02f623c2ab2661 non-successful status-
codes are already handled, and a 204 ("no content") status should not be an error,
this special case should no longer be needed.

Signed-off-by: Sebastiaan van Stijn &lt;github@gone.nl&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This was added in 93c3e6c91ec5eb4202b86b44b011d06f5e048dab, at which time only
some basic handling of non-succesful status codes was present;
https://github.com/moby/moby/blob/93c3e6c91ec5eb4202b86b44b011d06f5e048dab/api/client/utils.go#L112-L121

Given that since 38e6d474affe08230043fa36fa02f623c2ab2661 non-successful status-
codes are already handled, and a 204 ("no content") status should not be an error,
this special case should no longer be needed.

Signed-off-by: Sebastiaan van Stijn &lt;github@gone.nl&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>client: remove wrapResponseError()</title>
<updated>2022-03-20T18:04:52+00:00</updated>
<author>
<name>Sebastiaan van Stijn</name>
<email>github@gone.nl</email>
</author>
<published>2022-03-20T15:55:42+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/docker.git/commit/?id=45067cda330b4ebcc889b17856a60761aa480ad6'/>
<id>45067cda330b4ebcc889b17856a60761aa480ad6</id>
<content type='text'>
The wrapResponseError() utility converted some specific errors, but in
doing so, could hide the actual error message returned by the daemon.
In addition, starting with 38e6d474affe08230043fa36fa02f623c2ab2661,
HTTP status codes were already mapped to their corresponding errdefs
types on the client-side, making this conversion redundant.

This patch removes the wrapResponseError() utility; it's worth noting
that some error-messages will change slightly (as they now return the
error as returned by the daemon), but may cointain more details as
before, and in some cases prevents hiding the actual error.

Before this change:

    docker container rm nosuchcontainer
    Error: No such container: nosuchcontainer

    docker container cp mycontainer:/no/such/path .
    Error: No such container:path: mycontainer:/no/such/path

    docker container cp ./Dockerfile mycontainer:/no/such/path
    Error: No such container:path: mycontainer:/no/such

    docker image rm nosuchimage
    Error: No such image: nosuchimage

    docker network rm nosuchnetwork
    Error: No such network: nosuchnetwork

    docker volume rm nosuchvolume
    Error: No such volume: nosuchvolume

    docker plugin rm nosuchplugin
    Error: No such plugin: nosuchplugin

    docker checkpoint rm nosuchcontainer nosuchcheckpoint
    Error response from daemon: No such container: nosuchcontainer

    docker checkpoint rm mycontainer nosuchcheckpoint
    Error response from daemon: checkpoint nosuchcheckpoint does not exist for container mycontainer

    docker service rm nosuchservice
    Error: No such service: nosuchservice

    docker node rm nosuchnode
    Error: No such node: nosuchnode

    docker config rm nosuschconfig
    Error: No such config: nosuschconfig

    docker secret rm nosuchsecret
    Error: No such secret: nosuchsecret

After this change:

    docker container rm nosuchcontainer
    Error response from daemon: No such container: nosuchcontainer

    docker container cp mycontainer:/no/such/path .
    Error response from daemon: Could not find the file /no/such/path in container mycontainer

    docker container cp ./Dockerfile mycontainer:/no/such/path
    Error response from daemon: Could not find the file /no/such in container mycontainer

    docker image rm nosuchimage
    Error response from daemon: No such image: nosuchimage:latest

    docker network rm nosuchnetwork
    Error response from daemon: network nosuchnetwork not found

    docker volume rm nosuchvolume
    Error response from daemon: get nosuchvolume: no such volume

    docker plugin rm nosuchplugin
    Error response from daemon: plugin "nosuchplugin" not found

    docker checkpoint rm nosuchcontainer nosuchcheckpoint
    Error response from daemon: No such container: nosuchcontainer

    docker checkpoint rm mycontainer nosuchcheckpoint
    Error response from daemon: checkpoint nosuchcheckpoint does not exist for container mycontainer

    docker service rm nosuchservice
    Error response from daemon: service nosuchservice not found

    docker node rm nosuchnode
    Error response from daemon: node nosuchnode not found

    docker config rm nosuchconfig
    Error response from daemon: config nosuchconfig not found

    docker secret rm nosuchsecret
    Error response from daemon: secret nosuchsecret not found

Signed-off-by: Sebastiaan van Stijn &lt;github@gone.nl&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The wrapResponseError() utility converted some specific errors, but in
doing so, could hide the actual error message returned by the daemon.
In addition, starting with 38e6d474affe08230043fa36fa02f623c2ab2661,
HTTP status codes were already mapped to their corresponding errdefs
types on the client-side, making this conversion redundant.

This patch removes the wrapResponseError() utility; it's worth noting
that some error-messages will change slightly (as they now return the
error as returned by the daemon), but may cointain more details as
before, and in some cases prevents hiding the actual error.

Before this change:

    docker container rm nosuchcontainer
    Error: No such container: nosuchcontainer

    docker container cp mycontainer:/no/such/path .
    Error: No such container:path: mycontainer:/no/such/path

    docker container cp ./Dockerfile mycontainer:/no/such/path
    Error: No such container:path: mycontainer:/no/such

    docker image rm nosuchimage
    Error: No such image: nosuchimage

    docker network rm nosuchnetwork
    Error: No such network: nosuchnetwork

    docker volume rm nosuchvolume
    Error: No such volume: nosuchvolume

    docker plugin rm nosuchplugin
    Error: No such plugin: nosuchplugin

    docker checkpoint rm nosuchcontainer nosuchcheckpoint
    Error response from daemon: No such container: nosuchcontainer

    docker checkpoint rm mycontainer nosuchcheckpoint
    Error response from daemon: checkpoint nosuchcheckpoint does not exist for container mycontainer

    docker service rm nosuchservice
    Error: No such service: nosuchservice

    docker node rm nosuchnode
    Error: No such node: nosuchnode

    docker config rm nosuschconfig
    Error: No such config: nosuschconfig

    docker secret rm nosuchsecret
    Error: No such secret: nosuchsecret

After this change:

    docker container rm nosuchcontainer
    Error response from daemon: No such container: nosuchcontainer

    docker container cp mycontainer:/no/such/path .
    Error response from daemon: Could not find the file /no/such/path in container mycontainer

    docker container cp ./Dockerfile mycontainer:/no/such/path
    Error response from daemon: Could not find the file /no/such in container mycontainer

    docker image rm nosuchimage
    Error response from daemon: No such image: nosuchimage:latest

    docker network rm nosuchnetwork
    Error response from daemon: network nosuchnetwork not found

    docker volume rm nosuchvolume
    Error response from daemon: get nosuchvolume: no such volume

    docker plugin rm nosuchplugin
    Error response from daemon: plugin "nosuchplugin" not found

    docker checkpoint rm nosuchcontainer nosuchcheckpoint
    Error response from daemon: No such container: nosuchcontainer

    docker checkpoint rm mycontainer nosuchcheckpoint
    Error response from daemon: checkpoint nosuchcheckpoint does not exist for container mycontainer

    docker service rm nosuchservice
    Error response from daemon: service nosuchservice not found

    docker node rm nosuchnode
    Error response from daemon: node nosuchnode not found

    docker config rm nosuchconfig
    Error response from daemon: config nosuchconfig not found

    docker secret rm nosuchsecret
    Error response from daemon: secret nosuchsecret not found

Signed-off-by: Sebastiaan van Stijn &lt;github@gone.nl&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>refactor: move from io/ioutil to io and os package</title>
<updated>2021-08-27T06:56:57+00:00</updated>
<author>
<name>Eng Zer Jun</name>
<email>engzerjun@gmail.com</email>
</author>
<published>2021-08-24T10:10:50+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/docker.git/commit/?id=c55a4ac7795c7606b548b38e24673733481e2167'/>
<id>c55a4ac7795c7606b548b38e24673733481e2167</id>
<content type='text'>
The io/ioutil package has been deprecated in Go 1.16. This commit
replaces the existing io/ioutil functions with their new definitions in
io and os packages.

Signed-off-by: Eng Zer Jun &lt;engzerjun@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The io/ioutil package has been deprecated in Go 1.16. This commit
replaces the existing io/ioutil functions with their new definitions in
io and os packages.

Signed-off-by: Eng Zer Jun &lt;engzerjun@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Prepare tests for Windows containerd support</title>
<updated>2021-04-22T07:50:00+00:00</updated>
<author>
<name>Olli Janatuinen</name>
<email>olli.janatuinen@gmail.com</email>
</author>
<published>2021-03-18T15:55:11+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/docker.git/commit/?id=bffa730860f5b9453a0c08dce386ce1eb4ecd2e3'/>
<id>bffa730860f5b9453a0c08dce386ce1eb4ecd2e3</id>
<content type='text'>
Signed-off-by: Olli Janatuinen &lt;olli.janatuinen@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Olli Janatuinen &lt;olli.janatuinen@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Windows: Enable more integration tests</title>
<updated>2020-09-20T19:09:27+00:00</updated>
<author>
<name>Olli Janatuinen</name>
<email>olli.janatuinen@gmail.com</email>
</author>
<published>2020-09-15T19:43:16+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/docker.git/commit/?id=66a37b460c839ee7a9aca118840b441764292c97'/>
<id>66a37b460c839ee7a9aca118840b441764292c97</id>
<content type='text'>
Signed-off-by: Olli Janatuinen &lt;olli.janatuinen@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Olli Janatuinen &lt;olli.janatuinen@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>bump gotest.tools v3.0.1 for compatibility with Go 1.14</title>
<updated>2020-02-10T23:06:42+00:00</updated>
<author>
<name>Sebastiaan van Stijn</name>
<email>github@gone.nl</email>
</author>
<published>2020-02-07T13:39:24+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/docker.git/commit/?id=9f0b3f5609faf69537cdf1882c251deec6e9eb26'/>
<id>9f0b3f5609faf69537cdf1882c251deec6e9eb26</id>
<content type='text'>
full diff: https://github.com/gotestyourself/gotest.tools/compare/v2.3.0...v3.0.1

Signed-off-by: Sebastiaan van Stijn &lt;github@gone.nl&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
full diff: https://github.com/gotestyourself/gotest.tools/compare/v2.3.0...v3.0.1

Signed-off-by: Sebastiaan van Stijn &lt;github@gone.nl&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>testutil: make testing packages public</title>
<updated>2019-09-11T12:47:23+00:00</updated>
<author>
<name>Sam Whited</name>
<email>sam@samwhited.com</email>
</author>
<published>2019-08-29T20:52:40+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/docker.git/commit/?id=b37c214e3c8c4ff5450bd5fc1225d53827d240e7'/>
<id>b37c214e3c8c4ff5450bd5fc1225d53827d240e7</id>
<content type='text'>
This was done with something along the lines of:

```
mv internal/test testutil
pushd testutil/; grep -IRl "package test" | xargs -I '{}' sed -i -e 's|package test|package testutil|g' {}; popd
mv internal/testutil/*.go testutil/ &amp;&amp; rm -rf internal/
grep -IRl "github.com\/docker\/docker\/internal\/test" | xargs -I '{}' sed -i -e 's|github.com/docker/docker/internal/test|github.com/docker/docker/test|g' {}
goimports .
```

I also modified the basic plugin path in testutil/fixtures/plugin.

Signed-off-by: Sam Whited &lt;sam@samwhited.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This was done with something along the lines of:

```
mv internal/test testutil
pushd testutil/; grep -IRl "package test" | xargs -I '{}' sed -i -e 's|package test|package testutil|g' {}; popd
mv internal/testutil/*.go testutil/ &amp;&amp; rm -rf internal/
grep -IRl "github.com\/docker\/docker\/internal\/test" | xargs -I '{}' sed -i -e 's|github.com/docker/docker/internal/test|github.com/docker/docker/test|g' {}
goimports .
```

I also modified the basic plugin path in testutil/fixtures/plugin.

Signed-off-by: Sam Whited &lt;sam@samwhited.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>add more tests</title>
<updated>2019-06-13T06:31:05+00:00</updated>
<author>
<name>Tibor Vass</name>
<email>tibor@docker.com</email>
</author>
<published>2019-06-13T05:36:21+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/docker.git/commit/?id=02f1eb89a42b4a9e91a8c80c213f7dc3193c75b9'/>
<id>02f1eb89a42b4a9e91a8c80c213f7dc3193c75b9</id>
<content type='text'>
Signed-off-by: Tibor Vass &lt;tibor@docker.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Tibor Vass &lt;tibor@docker.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
