func (s *configFunctionalSuite) TestWrite(c *gc.C) { dirname := c.MkDir() cfg := lxdclient.Config{ Namespace: "my-ns", Dirname: dirname, Remote: s.remote, } err := cfg.Write() c.Assert(err, jc.ErrorIsNil) checkFiles(c, cfg) }
func (s *configSuite) TestWriteInvalid(c *gc.C) { var cfg lxdclient.Config err := cfg.Write() c.Check(err, jc.Satisfies, errors.IsNotValid) }