Skip to content

Commit

Permalink
Move integration-cli daemon package to internal/test…
Browse files Browse the repository at this point in the history
… and do not use the `docker` cli in it. One of the reason of this
move is to not make `integration` package using legacy
`integration-cli` package.

Next move will be to support swarm within this package *and* provide
some helper function using the api (compared to the one using cli in
`integration-cli/daemon` package).

Signed-off-by: Vincent Demeester <[email protected]>
  • Loading branch information
vdemeester committed Apr 10, 2018
1 parent fb08a5c commit f0d277f
Show file tree
Hide file tree
Showing 20 changed files with 677 additions and 637 deletions.
7 changes: 4 additions & 3 deletions integration-cli/check_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import (
"github.com/docker/docker/integration-cli/environment"
"github.com/docker/docker/integration-cli/fixtures/plugin"
"github.com/docker/docker/integration-cli/registry"
testdaemon "github.com/docker/docker/internal/test/daemon"
ienv "github.com/docker/docker/internal/test/environment"
"github.com/docker/docker/pkg/reexec"
"github.com/go-check/check"
Expand Down Expand Up @@ -100,7 +101,7 @@ func (s *DockerSuite) OnTimeout(c *check.C) {

daemonPid := int(rawPid)
if daemonPid > 0 {
daemon.SignalDaemonDump(daemonPid)
testdaemon.SignalDaemonDump(daemonPid)
}
}

Expand Down Expand Up @@ -285,7 +286,7 @@ func (s *DockerDaemonSuite) TearDownTest(c *check.C) {
}

func (s *DockerDaemonSuite) TearDownSuite(c *check.C) {
filepath.Walk(daemon.SockRoot, func(path string, fi os.FileInfo, err error) error {
filepath.Walk(testdaemon.SockRoot, func(path string, fi os.FileInfo, err error) error {
if err != nil {
// ignore errors here
// not cleaning up sockets is not really an error
Expand All @@ -296,7 +297,7 @@ func (s *DockerDaemonSuite) TearDownSuite(c *check.C) {
}
return nil
})
os.RemoveAll(daemon.SockRoot)
os.RemoveAll(testdaemon.SockRoot)
}

const defaultSwarmPort = 2477
Expand Down
Loading

0 comments on commit f0d277f

Please sign in to comment.