mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-08-22 07:06:51 +00:00
fix: close leaked replica in TestShip_DegradedDoesNotSilently
The test used createSyncAllPair(t) but discarded the replica return value, leaving the volume file open. On Windows this caused TempDir cleanup failure. All 7 CP13-1 baseline FAILs now PASS. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
3e9358f2be
commit
4ed54d04ba
@@ -462,8 +462,9 @@ func TestWalRetention_RequiredReplicaBlocksReclaim(t *testing.T) {
|
||||
// This is acceptable for best_effort but problematic for sync_all because
|
||||
// the primary loses track of the replica gap size.
|
||||
func TestShip_DegradedDoesNotSilentlyCountAsHealthy(t *testing.T) {
|
||||
primary, _ := createSyncAllPair(t)
|
||||
primary, replica := createSyncAllPair(t)
|
||||
defer primary.Close()
|
||||
defer replica.Close()
|
||||
|
||||
// Point shipper at dead address — will degrade on first Ship.
|
||||
primary.SetReplicaAddr("127.0.0.1:1", "127.0.0.1:2")
|
||||
|
||||
Reference in New Issue
Block a user