Refactor repository structure

Merge Map data type into Tree.
This commit is contained in:
Alexander Neumann committed 2015-01-14 16:34:30 +01:00
1 parent bdcdcdea7d
commit 203a911de9
26 files changed
+939 -681

No files matched your search

+14
View File
@@ -76,3 +76,17 @@ func TestNodeMarshal(t *testing.T) {
}
}
}
func TestNodeComparison(t *testing.T) {
fi, err := os.Lstat("tree_test.go")
ok(t, err)
node, err := restic.NodeFromFileInfo("foo", fi)
ok(t, err)
n2 := *node
assert(t, node.Equals(n2), "nodes aren't equal")
n2.Size -= 1
assert(t, !node.Equals(n2), "nodes are equal")
}