Fix release notes
[ric-plt/e2mgr.git] / E2Manager / handlers / rmrmsghandlers / ran_lost_connection_handler_test.go
index 8e1464f..ff43136 100644 (file)
@@ -1,4 +1,3 @@
-////
 //// Copyright 2019 AT&T Intellectual Property
 //// Copyright 2019 Nokia
 ////
 //// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 //// See the License for the specific language governing permissions and
 //// limitations under the License.
+
+//  This source code is part of the near-RT RIC (RAN Intelligent Controller)
+//  platform project (RICP).
+
 ////
 package rmrmsghandlers
 
@@ -20,7 +23,6 @@ import (
        "e2mgr/logger"
        "e2mgr/mocks"
        "e2mgr/models"
-       "e2mgr/sessions"
        "github.com/pkg/errors"
        "testing"
 )
@@ -31,8 +33,8 @@ func TestLostConnectionHandlerSuccess(t *testing.T) {
        notificationRequest := models.NotificationRequest{RanName: ranName}
        ranReconnectionManagerMock := &mocks.RanReconnectionManagerMock{}
        ranReconnectionManagerMock.On("ReconnectRan", ranName).Return(nil)
-       handler := NewRanLostConnectionHandler(ranReconnectionManagerMock)
-       handler.Handle(logger, make(sessions.E2Sessions), &notificationRequest, nil)
+       handler := NewRanLostConnectionHandler(logger, ranReconnectionManagerMock)
+       handler.Handle(&notificationRequest)
        ranReconnectionManagerMock.AssertCalled(t, "ReconnectRan", ranName)
 }
 
@@ -42,7 +44,7 @@ func TestLostConnectionHandlerFailure(t *testing.T) {
        notificationRequest := models.NotificationRequest{RanName: ranName}
        ranReconnectionManagerMock := &mocks.RanReconnectionManagerMock{}
        ranReconnectionManagerMock.On("ReconnectRan", ranName).Return(errors.New("error"))
-       handler := NewRanLostConnectionHandler(ranReconnectionManagerMock)
-       handler.Handle(logger, make(sessions.E2Sessions), &notificationRequest, nil)
+       handler := NewRanLostConnectionHandler(logger, ranReconnectionManagerMock)
+       handler.Handle(&notificationRequest)
        ranReconnectionManagerMock.AssertCalled(t, "ReconnectRan", ranName)
-}
\ No newline at end of file
+}