(c *C)
| 72 | } |
| 73 | |
| 74 | func (s *NoderSuite) TestDiffChangeContent(c *C) { |
| 75 | fsA := memfs.New() |
| 76 | WriteFile(fsA, "foo", []byte("foo"), 0644) |
| 77 | WriteFile(fsA, "qux/bar", []byte("foo"), 0644) |
| 78 | WriteFile(fsA, "qux/qux", []byte("foo"), 0644) |
| 79 | |
| 80 | fsB := memfs.New() |
| 81 | WriteFile(fsB, "foo", []byte("foo"), 0644) |
| 82 | WriteFile(fsB, "qux/bar", []byte("bar"), 0644) |
| 83 | WriteFile(fsB, "qux/qux", []byte("foo"), 0644) |
| 84 | |
| 85 | ch, err := merkletrie.DiffTree( |
| 86 | NewRootNode(fsA, nil), |
| 87 | NewRootNode(fsB, nil), |
| 88 | IsEquals, |
| 89 | ) |
| 90 | |
| 91 | c.Assert(err, IsNil) |
| 92 | c.Assert(ch, HasLen, 1) |
| 93 | } |
| 94 | |
| 95 | func (s *NoderSuite) TestDiffSymlinkDirOnA(c *C) { |
| 96 | fsA := memfs.New() |
nothing calls this directly
no test coverage detected