Code Review
/
ric-plt
/
submgr.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Verify all clean function added for unit tests
[ric-plt/submgr.git]
/
pkg
/
control
/
sdl_restSubsDb_test.go
diff --git
a/pkg/control/sdl_restSubsDb_test.go
b/pkg/control/sdl_restSubsDb_test.go
index
273a15e
..
3db8a2d
100644
(file)
--- 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)
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) {
}
func TestReadRESTSubscriptionFromSdl(t *testing.T) {