MCPcopy Create free account
hub / github.com/go-git/go-git / TestStatusAfterCheckout

Method TestStatusAfterCheckout

worktree_test.go:1261–1275  ·  view source on GitHub ↗
(c *C)

Source from the content-addressed store, hash-verified

1259}
1260
1261func (s *WorktreeSuite) TestStatusAfterCheckout(c *C) {
1262 fs := memfs.New()
1263 w := &Worktree{
1264 r: s.Repository,
1265 Filesystem: fs,
1266 }
1267
1268 err := w.Checkout(&CheckoutOptions{Force: true})
1269 c.Assert(err, IsNil)
1270
1271 status, err := w.Status()
1272 c.Assert(err, IsNil)
1273 c.Assert(status.IsClean(), Equals, true)
1274
1275}
1276
1277func (s *WorktreeSuite) TestStatusModified(c *C) {
1278 fs, clean := s.TemporalFilesystem()

Callers

nothing calls this directly

Calls 3

CheckoutMethod · 0.95
StatusMethod · 0.95
IsCleanMethod · 0.45

Tested by

no test coverage detected