From 6bde6ad22fc848bb9275e87f61bad2f38814fdf9 Mon Sep 17 00:00:00 2001 From: Haiko Schol Date: Thu, 31 Oct 2024 16:05:17 +0700 Subject: [PATCH] test(dot): fix two tests on MacOS (#4284) --- dot/services_test.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/dot/services_test.go b/dot/services_test.go index d33032aff2..dc00462f69 100644 --- a/dot/services_test.go +++ b/dot/services_test.go @@ -30,6 +30,8 @@ func Test_createRuntimeStorage(t *testing.T) { stateSrvc, err := builder.createStateService(config) require.NoError(t, err) + require.NoError(t, stateSrvc.Start()) + tests := []struct { name string service *state.Service @@ -51,6 +53,8 @@ func Test_createRuntimeStorage(t *testing.T) { assert.NotNil(t, got.PersistentStorage) }) } + + require.NoError(t, stateSrvc.Stop()) } func Test_createSystemService(t *testing.T) { @@ -65,6 +69,8 @@ func Test_createSystemService(t *testing.T) { stateSrvc, err := builder.createStateService(config) require.NoError(t, err) + require.NoError(t, stateSrvc.Start()) + type args struct { cfg *types.SystemInfo service *state.Service @@ -96,6 +102,8 @@ func Test_createSystemService(t *testing.T) { } }) } + + require.NoError(t, stateSrvc.Stop()) } func Test_newInMemoryDB(t *testing.T) {