func isRemoved(st *state.State, name string) func(*C) bool { return func(c *C) bool { _, err := st.Unit(name) if errors.IsNotFoundError(err) { return true } c.Assert(err, IsNil) return false } }
func (a *UnitAgent) Entity(st *state.State) (AgentState, error) { return st.Unit(a.UnitName) }