2 * Copyright (c) 2014 Cisco Systems, Inc. and others. All rights reserved.
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
9 package org.opendaylight.openflowplugin.openflow.md.core;
11 import static org.junit.Assert.assertNotNull;
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.statistics.MessageSpy;
20 import org.opendaylight.yangtools.yang.binding.DataContainer;
23 * Created by Martin Bobak mbobak@cisco.com on 8/29/14.
25 @RunWith(MockitoJUnitRunner.class)
26 public class SwitchConnectionHandlerImplTest {
30 private ErrorHandler errorHandler;
32 private MessageSpy<DataContainer> messageSpy;
34 private ConnectionAdapter connectionAdapter;
37 * Test method for SwitchConnectionHandlerImpl initialization.
40 public void basicInitializationTest() {
41 SwitchConnectionHandlerImpl switchConnectionHandler = new SwitchConnectionHandlerImpl();
42 assertNotNull(switchConnectionHandler);
43 switchConnectionHandler.setMessageSpy(messageSpy);
44 switchConnectionHandler.setErrorHandler(errorHandler);