Shard by-id mount entries

This commit is contained in:
Jan Bader
2026-07-13 23:14:21 +02:00
parent 385ad6adad
commit ef8caef37b
2 changed files with 20 additions and 3 deletions
+6 -2
View File
@@ -87,9 +87,13 @@ func TestBuildMountTreeAddsByIDDirectory(t *testing.T) {
if !ok {
t.Fatalf("expected by-id directory, got %#v", root.children)
}
shard, ok := byID.children["it"].(*dirNode)
if !ok {
t.Fatalf("expected by-id shard, got %#v", byID.children)
}
for _, name := range []string{"item-1.pdf", "item-1-2.txt", "item-1-3.pdf"} {
if _, ok := byID.children[name].(*fileNode); !ok {
t.Fatalf("expected %s in by-id, got %#v", name, byID.children)
if _, ok := shard.children[name].(*fileNode); !ok {
t.Fatalf("expected %s in by-id shard, got %#v", name, shard.children)
}
}
}