~axwalk/juju-core/lp1211147-deployer-check-isstateserver

« back to all changes in this revision

Viewing changes to worker/deployer/export_test.go

  • Committer: Andrew Wilkins
  • Date: 2013-08-15 04:01:53 UTC
  • Revision ID: andrew.wilkins@canonical.com-20130815040153-e662cll3fruihnvp
worker/deployer: add flag to control syslog fwd

- Add flag to NewSimpleContext to enable syslog forwarding
- Add util function in api/agent, HasJobs(*Entity, params.MachineJob)
- Update jujud to make use of these

Show diffs side-by-side

added added

removed removed

Lines of Context:
13
13
        return []string{"a1:123", "a2:123"}, nil
14
14
}
15
15
 
16
 
func NewTestSimpleContext(initDir, dataDir, logDir, syslogConfigDir string) *SimpleContext {
 
16
func NewTestSimpleContext(initDir, dataDir, logDir, syslogConfigDir string, forwardSyslog bool) *SimpleContext {
17
17
        return &SimpleContext{
18
18
                addresser:       &fakeAddresser{},
19
19
                caCert:          []byte("test-cert"),
21
21
                dataDir:         dataDir,
22
22
                logDir:          logDir,
23
23
                syslogConfigDir: syslogConfigDir,
 
24
                forwardSyslog:   forwardSyslog,
24
25
        }
25
26
}