func (s *serviceManagerSuite) TestDelete(c *gc.C) { windows.AddService(s.name, s.execPath, s.stub, svc.Status{State: svc.Running}) err := s.mgr.Delete(s.name) c.Assert(err, gc.IsNil) exists := s.conn.Exists(s.name) c.Assert(exists, jc.IsFalse) }
func (s *serviceManagerSuite) TestStart(c *gc.C) { windows.AddService(s.name, s.execPath, s.stub, svc.Status{State: svc.Stopped}) err := s.mgr.Start(s.name) c.Assert(err, gc.IsNil) running, err := s.mgr.Running(s.name) c.Assert(err, gc.IsNil) c.Assert(running, jc.IsTrue) }