mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-11-12 06:48:45 +01:00
fix(test): use safe slice concatenation in manifest test
Avoid append(manifest1, manifest2...) which can mutate manifest1's backing array. Use the copy-then-append pattern for consistency. Addresses CodeRabbit review nitpick.
This commit is contained in:
1 parent
e0433d0a65
commit
dc609f4f6f
1 file changed
+1
-1
@@ -280,7 +280,7 @@ func TestCompactResolvedOverlappingManifests(t *testing.T) {
|
||||
}
|
||||
|
||||
// Resolve all manifests into sub-chunks
|
||||
allChunks := append(manifest1, manifest2...)
|
||||
allChunks := append(append([]*filer_pb.FileChunk{}, manifest1...), manifest2...)
|
||||
dataChunks, _, err := store.resolveAll(allChunks)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
|
||||
Reference in new issue
Block a user