(c *C)
| 16 | var _ = Suite(&SuiteCommon{}) |
| 17 | |
| 18 | func (s *SuiteCommon) TestNewContext(c *C) { |
| 19 | h := NewScheduler(&TestLogger{}) |
| 20 | j := &TestJob{} |
| 21 | j.Use(&TestMiddleware{}) |
| 22 | |
| 23 | e := NewExecution() |
| 24 | |
| 25 | ctx := NewContext(h, j, e) |
| 26 | c.Assert(ctx.Scheduler, DeepEquals, h) |
| 27 | c.Assert(ctx.Job, DeepEquals, j) |
| 28 | c.Assert(ctx.Execution, DeepEquals, e) |
| 29 | c.Assert(ctx.middlewares, HasLen, 1) |
| 30 | } |
| 31 | |
| 32 | func (s *SuiteCommon) TestContextNextError(c *C) { |
| 33 | mA := &TestMiddlewareAltA{} |
nothing calls this directly
no test coverage detected