testutil: update WithInitsignature to be a daemon.Option
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
parent
554d9cec25
commit
f60d6ee4bc
2 changed files with 5 additions and 3 deletions
|
@ -33,7 +33,7 @@ func testServiceCreateInit(daemonEnabled bool) func(t *testing.T) {
|
|||
var ops = []daemon.Option{}
|
||||
|
||||
if daemonEnabled {
|
||||
ops = append(ops, daemon.WithInit)
|
||||
ops = append(ops, daemon.WithInit())
|
||||
}
|
||||
d := swarm.NewSwarm(t, testEnv, ops...)
|
||||
defer d.Stop(t)
|
||||
|
|
|
@ -31,9 +31,11 @@ func WithExperimental() Option {
|
|||
}
|
||||
|
||||
// WithInit sets the daemon init
|
||||
func WithInit(d *Daemon) {
|
||||
func WithInit() Option {
|
||||
return func(d *Daemon) {
|
||||
d.init = true
|
||||
}
|
||||
}
|
||||
|
||||
// WithDockerdBinary sets the dockerd binary to the specified one
|
||||
func WithDockerdBinary(dockerdBinary string) Option {
|
||||
|
|
Loading…
Reference in a new issue