Merge "Debug tool for openconfig proprietary extensions"
[transportpce.git] / dmaap-client / src / test / java / org / opendaylight / transportpce / dmaap / client / impl / DmaapClientProviderTest.java
1 /*
2  * Copyright © 2021 Orange, Inc. and others.  All rights reserved.
3  *
4  * This program and the accompanying materials are made available under the
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6  * and is available at http://www.eclipse.org/legal/epl-v10.html
7  */
8 package org.opendaylight.transportpce.dmaap.client.impl;
9
10 import static org.mockito.Mockito.times;
11 import static org.mockito.Mockito.verify;
12
13 import org.junit.jupiter.api.BeforeEach;
14 import org.junit.jupiter.api.Test;
15 import org.mockito.Mock;
16 import org.mockito.Mockito;
17 import org.mockito.MockitoAnnotations;
18 import org.opendaylight.mdsal.binding.api.NotificationService;
19
20
21 public class DmaapClientProviderTest {
22
23     @Mock
24     private NotificationService notificationService;
25
26     @BeforeEach
27     void init() {
28         MockitoAnnotations.openMocks(this);
29     }
30
31     @Test
32     void testInitRegisterNbiNotificationsToRpcRegistry() {
33         new DmaapClientProvider(notificationService, "http://localhost", "username", "password");
34         verify(notificationService, times(1))
35             .registerCompositeListener(Mockito.any(NotificationService.CompositeListener.class));
36     }
37
38 }