diff --git a/client/alloc_runner_test.go b/client/alloc_runner_test.go index 390117926..649dbdebc 100644 --- a/client/alloc_runner_test.go +++ b/client/alloc_runner_test.go @@ -405,6 +405,10 @@ func TestAllocRunner_SaveRestoreState_TerminalAlloc(t *testing.T) { t.Fatalf("err: %v", err) } + // Ensure ar1 doesn't recreate the state file + ar.persistLock.Lock() + defer ar.persistLock.Unlock() + // Ensure both alloc runners don't destroy ar.destroy = true