(c *C)
| 94 | } |
| 95 | |
| 96 | func (s *ModulesSuite) TestValidateGoodName(c *C) { |
| 97 | for _, n := range []string{"foo", "lib-foo", "deps/x", "x.y"} { |
| 98 | m := &Submodule{ |
| 99 | Name: n, |
| 100 | Path: "ok", |
| 101 | URL: "https://example.com/", |
| 102 | } |
| 103 | c.Assert(m.Validate(), IsNil, Commentf("name %q", n)) |
| 104 | } |
| 105 | } |
| 106 | |
| 107 | func (s *ModulesSuite) TestMarshal(c *C) { |
| 108 | input := []byte(`[submodule "qux"] |