@@ -0,0 +1,2393 @@
+package net.robobalasko.dfa.core;%0A%0A%0Aimport net.robobalasko.dfa.core.exceptions.MultipleStartNodesException;%0Aimport net.robobalasko.dfa.core.exceptions.NodeConnectionException;%0Aimport org.junit.After;%0Aimport org.junit.Before;%0Aimport org.junit.Test;%0A%0Aimport java.util.LinkedList;%0A%0Aimport static org.junit.Assert.*;%0A%0Apublic class NodeConnectionStateTest %7B%0A%0A    private NodeConnectionState nodeConnectionState;%0A%0A    @Before%0A    public void setUp() %7B%0A        nodeConnectionState = new NodeConnectionState();%0A    %7D%0A%0A    @Test%0A    public void testResetConnectionStateSucceeds() %7B%0A        nodeConnectionState.resetConnectionState();%0A        assertNull(nodeConnectionState.getStartNode());%0A        assertNull(nodeConnectionState.getEndNode());%0A        assertFalse(nodeConnectionState.isConnecting());%0A    %7D%0A%0A    @Test(expected = NodeConnectionException.class)%0A    public void testConnectNodesFails() throws MultipleStartNodesException, NodeConnectionException %7B%0A        nodeConnectionState.connectNodes();%0A    %7D%0A%0A    @Test%0A    public void testConnectNodesSucceeds() throws MultipleStartNodesException, NodeConnectionException %7B%0A        StateNode firstNode = new StateNode('a', false, false, new LinkedList%3CStateNode%3E(), null);%0A        StateNode secondNode = new StateNode('b', false, false, new LinkedList%3CStateNode%3E(), null);%0A        nodeConnectionState.setStartNode(firstNode);%0A        nodeConnectionState.setEndNode(secondNode);%0A        nodeConnectionState.connectNodes();%0A        assertEquals('a', nodeConnectionState.getStartNode().getName());%0A        assertEquals('b', nodeConnectionState.getEndNode().getName());%0A    %7D%0A%0A    @Test%0A    public void testSetStartNode() %7B%0A        StateNode startNode = new StateNode('a', false, false, null, null);%0A        nodeConnectionState.setStartNode(startNode);%0A        assertEquals('a', nodeConnectionState.getStartNode().getName());%0A        assertTrue(nodeConnectionState.getStartNode().isActive());%0A        assertTrue(nodeConnectionState.isConnecting());%0A    %7D%0A%0A    @Test%0A    public void testSetEndNode() %7B%0A        StateNode endNode = new StateNode('b', false, false, null, null);%0A        nodeConnectionState.setEndNode(endNode);%0A        assertEquals('b', nodeConnectionState.getEndNode().getName());%0A        assertTrue(nodeConnectionState.getEndNode().isActive());%0A    %7D%0A%0A    @After%0A    public void tearDown() %7B%0A        nodeConnectionState = null;%0A    %7D%0A%0A%7D%0A

Add tests for NodeConnectionState class.