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
Fix for Submgr crash added
[ric-plt/submgr.git]
/
pkg
/
control
/
ut_ctrl_submgr_test.go
diff --git
a/pkg/control/ut_ctrl_submgr_test.go
b/pkg/control/ut_ctrl_submgr_test.go
index
16c69b1
..
e514cb0
100644
(file)
--- a/
pkg/control/ut_ctrl_submgr_test.go
+++ b/
pkg/control/ut_ctrl_submgr_test.go
@@
-55,6
+55,7
@@
func createSubmgrControl(srcId teststub.RmrSrcId, rtgSvc teststub.RmrRtgSvc) *te
mainCtrl = &testingSubmgrControl{}
mainCtrl.RmrControl.Init("SUBMGRCTL", srcId, rtgSvc)
mainCtrl.c = NewControl()
mainCtrl = &testingSubmgrControl{}
mainCtrl.RmrControl.Init("SUBMGRCTL", srcId, rtgSvc)
mainCtrl.c = NewControl()
+ mainCtrl.c.UTTesting = true
mainCtrl.c.LoggerLevel = int(xapp.Logger.GetLevel())
xapp.Logger.Debug("Test: LoggerLevel %v", mainCtrl.c.LoggerLevel)
xapp.Logger.Debug("Replacing real db with test db")
mainCtrl.c.LoggerLevel = int(xapp.Logger.GetLevel())
xapp.Logger.Debug("Test: LoggerLevel %v", mainCtrl.c.LoggerLevel)
xapp.Logger.Debug("Replacing real db with test db")
@@
-72,7
+73,7
@@
func (mc *testingSubmgrControl) SimulateRestart(t *testing.T) {
mainCtrl.c.registry.subIds = nil
// Initialize subIds slice and subscription map
mainCtrl.c.registry.Initialize()
mainCtrl.c.registry.subIds = nil
// Initialize subIds slice and subscription map
mainCtrl.c.registry.Initialize()
- restDuplicateCtrl.Init()
+
mainCtrl.c.
restDuplicateCtrl.Init()
// Read subIds and subscriptions from database
subIds, register, err := mainCtrl.c.ReadAllSubscriptionsFromSdl()
if err != nil {
// Read subIds and subscriptions from database
subIds, register, err := mainCtrl.c.ReadAllSubscriptionsFromSdl()
if err != nil {