unifying statistics manager api packages
[openflowplugin.git] / openflowplugin / src / test / java / org / opendaylight / openflowplugin / openflow / md / core / SwitchConnectionHandlerImplTest.java
1 /*
2  * Copyright (c) 2014 Cisco Systems, 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
9 package org.opendaylight.openflowplugin.openflow.md.core;
10
11 import static org.junit.Assert.assertNotNull;
12
13 import org.junit.Test;
14 import org.junit.runner.RunWith;
15 import org.mockito.Mock;
16 import org.mockito.runners.MockitoJUnitRunner;
17 import org.opendaylight.openflowjava.protocol.api.connection.ConnectionAdapter;
18 import org.opendaylight.openflowplugin.api.openflow.md.core.ErrorHandler;
19 import org.opendaylight.openflowplugin.api.openflow.statistics.MessageSpy;
20 import org.opendaylight.yangtools.yang.binding.DataContainer;
21
22 /**
23  * Created by Martin Bobak mbobak@cisco.com on 8/29/14.
24  */
25 @RunWith(MockitoJUnitRunner.class)
26 public class SwitchConnectionHandlerImplTest {
27
28
29     @Mock
30     private ErrorHandler errorHandler;
31     @Mock
32     private MessageSpy<DataContainer> messageSpy;
33     @Mock
34     private ConnectionAdapter connectionAdapter;
35
36     /**
37      * Test method for SwitchConnectionHandlerImpl initialization.
38      */
39     @Test
40     public void basicInitializationTest() {
41         SwitchConnectionHandlerImpl switchConnectionHandler = new SwitchConnectionHandlerImpl();
42         assertNotNull(switchConnectionHandler);
43         switchConnectionHandler.setMessageSpy(messageSpy);
44         switchConnectionHandler.setErrorHandler(errorHandler);
45     }
46
47 }