func (s *configSuite) TestValidateMissingRemote(c *gc.C) { cfg := lxdclient.Config{ Namespace: "my-ns", } err := cfg.Validate() c.Check(err, jc.Satisfies, errors.IsNotValid) }
func (s *configSuite) TestValidateOnlyRemote(c *gc.C) { cfg := lxdclient.Config{ Remote: s.remote, } err := cfg.Validate() c.Check(err, jc.ErrorIsNil) }
func (s *configSuite) TestValidateOkay(c *gc.C) { cfg := lxdclient.Config{ Namespace: "my-ns", Remote: s.remote, } err := cfg.Validate() c.Check(err, jc.ErrorIsNil) }
func (s *configSuite) TestValidateZeroValue(c *gc.C) { var cfg lxdclient.Config err := cfg.Validate() c.Check(err, jc.Satisfies, errors.IsNotValid) }