@@ -0,0 +1,2002 @@
+package net.robobalasko.dfa.core;%0A%0Aimport net.robobalasko.dfa.core.exceptions.MultipleStartNodesException;%0Aimport net.robobalasko.dfa.core.exceptions.NodeConnectionMissingException;%0Aimport org.junit.After;%0Aimport org.junit.Before;%0Aimport org.junit.Test;%0A%0Aimport java.awt.*;%0Aimport java.util.LinkedList;%0A%0Aimport static org.junit.Assert.*;%0A%0Apublic class StateNodeTest %7B%0A%0A    private StateNode node;%0A%0A    @Before%0A    public void setUp() %7B%0A        node = new StateNode('a', true, true, new LinkedList%3CStateNode%3E(), new Point(0, 0));%0A    %7D%0A%0A    @Test(expected = MultipleStartNodesException.class)%0A    public void testAddConnectionFails() throws MultipleStartNodesException %7B%0A        StateNode connection = new StateNode('a', true, false, null, null);%0A        node.addConnection(connection);%0A    %7D%0A%0A    @Test%0A    public void testAddConnectionSucceeds() throws MultipleStartNodesException %7B%0A        StateNode connection = new StateNode('a', false, false, null, null);%0A        node.addConnection(connection);%0A    %7D%0A%0A    @Test%0A    public void testIsConnectedToFails() %7B%0A        assertFalse(node.isConnectedTo('b'));%0A    %7D%0A%0A    @Test%0A    public void testIsConnectedToSucceeds() throws MultipleStartNodesException %7B%0A        StateNode connection = new StateNode('b', false, false, null, null);%0A        node.addConnection(connection);%0A        assertTrue(node.isConnectedTo('b'));%0A    %7D%0A%0A    @Test(expected = NodeConnectionMissingException.class)%0A    public void testGetConnectedViaFails() throws NodeConnectionMissingException %7B%0A        node.getNodeConnectedVia('b');%0A    %7D%0A%0A    @Test%0A    public void testGetConnectedViaSucceeds() throws NodeConnectionMissingException, MultipleStartNodesException %7B%0A        StateNode connection = new StateNode('b', false, false, null, null);%0A        node.addConnection(connection);%0A        StateNode foundConnection = node.getNodeConnectedVia('b');%0A        assertEquals('b', foundConnection.getName());%0A    %7D%0A%0A    @After%0A    public void tearDown() %7B%0A        node = null;%0A    %7D%0A%0A%7D%0A

Add State node test.