in mock/deps.go [81:114]
func Deps() deps.Deps {
cfg := config.Defaults()
cfg.Set(param.Enabled, true)
cfg.Set(param.Leashed, false)
cfg.Set(param.Accounts, []string{"prod", "test"})
f, err := ioutil.TempFile("", "cm-test")
if err != nil {
panic(err)
}
// The ioutil.TempFile opens the file, but we
// don't need it open, since we are just going
// to pass the file name along via the CronPath
// function, so we just close it
err = f.Close()
if err != nil {
panic(err)
}
cfg.Set(param.CronPath, f.Name())
return deps.Deps{
MonkeyCfg: cfg,
Checker: Checker{Error: nil},
ConfGetter: DefaultConfigGetter(),
Cl: clock.New(),
Dep: Dep(),
T: new(Terminator),
Ou: Outage{},
ErrCounter: ErrorCounter{},
Env: Env{false},
}
}