Exemplo n.º 1
0
func (s *FactorySuite) AssertNotActionContext(c *gc.C, ctx runner.Context) {
	actionData, err := ctx.ActionData()
	c.Assert(actionData, gc.IsNil)
	c.Assert(err, gc.ErrorMatches, "not running an action")
}
Exemplo n.º 2
0
func (s *HookContextSuite) AssertActionContext(c *gc.C, ctx runner.Context) {
	actionData, err := ctx.ActionData()
	c.Assert(actionData, gc.NotNil)
	c.Assert(err, jc.ErrorIsNil)
}