X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=pkg%2Fcontrol%2Fsdl_restSubsDb_test.go;h=3db8a2d94e7f8061581e967f4534b77023ddb356;hb=e60d7b6dc1c2244ef9f885d03984d2bd238a49e0;hp=273a15e1fb5053b70e6ddd346cb31662b8213893;hpb=40a8b1be512bd1dc42a681685980c4ac99b298a4;p=ric-plt%2Fsubmgr.git diff --git a/pkg/control/sdl_restSubsDb_test.go b/pkg/control/sdl_restSubsDb_test.go index 273a15e..3db8a2d 100644 --- a/pkg/control/sdl_restSubsDb_test.go +++ b/pkg/control/sdl_restSubsDb_test.go @@ -120,6 +120,17 @@ func TestWriteRESTSubscriptionToSdl(t *testing.T) { t.Errorf("TEST: %s", err.Error()) } restSubsDbMock.AddRestSubIdsInDb(restSubId) + verifyRESTKeyCount(t, 1) +} + +func verifyRESTKeyCount(t *testing.T, expectedCount int) { + + count, err := mainCtrl.c.GetRESTKeyCount() + if err != nil { + t.Errorf("TEST: %s", err.Error()) + } else { + assert.Equal(t, expectedCount, count) + } } func TestReadRESTSubscriptionFromSdl(t *testing.T) {