[#1657] engine: Fix data race in evacuation tests
All checks were successful
DCO action / DCO (pull_request) Successful in 36s
Vulncheck / Vulncheck (pull_request) Successful in 1m16s
Build / Build Components (pull_request) Successful in 1m34s
Pre-commit hooks / Pre-commit (pull_request) Successful in 1m54s
Tests and linters / Tests (pull_request) Successful in 2m32s
Tests and linters / Lint (pull_request) Successful in 2m34s
Tests and linters / Run gofumpt (pull_request) Successful in 2m34s
Tests and linters / Staticcheck (pull_request) Successful in 2m47s
Tests and linters / gopls check (pull_request) Successful in 3m8s
Tests and linters / Tests with -race (pull_request) Successful in 3m59s

Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
Dmitrii Stepanov 2025-02-28 14:51:35 +03:00
parent dae0949f6e
commit f448babb99
Signed by: dstepanov-yadro
GPG key ID: 237AF1A763293BC0

View file

@ -475,7 +475,7 @@ func TestEvacuateObjectsAsync(t *testing.T) {
eg, egCtx := errgroup.WithContext(context.Background())
eg.Go(func() error {
require.NoError(t, e.Evacuate(egCtx, prm), "first evacuation failed")
st = testWaitForEvacuationCompleted(t, e)
st := testWaitForEvacuationCompleted(t, e)
require.Equal(t, uint64(3), st.ObjectsEvacuated(), "invalid final count")
return nil
})