private void testFailure()
	{
		try
		{
			tests++;
			printDebugInfo("Failure test", "Press 'enter' to continu...");
			commandLineWait();
			
			printDebugInfo("Failure test", "Login three new nodes to the network and press 'enter' to continu...");
			commandLineWait();
			
			HashMap<Integer, Node> nodeList = server.getNodeList();
			assert(nodeList.size() == 3) : "The number of nodes do not equal 3! (" + nodeList.size() + " nodes available)";
			
			Node node1 = (Node)nodeList.values().toArray()[0];
			Node node2 = (Node)nodeList.values().toArray()[1];
			Node node3 = (Node)nodeList.values().toArray()[2];
			
			Node prevNode1 = null;
			Node nextNode1 = null;			
			Node prevNode2 = null;
			Node nextNode2 = null;
			Node prevNode3 = null;
			Node nextNode3 = null;
			
			NodeLinkManagerInterface iFace1 = null;
			NodeLinkManagerInterface iFace3 = null;
			NodeLinkManagerInterface iFace2 = null;
			
			try
			{
				iFace1 = (NodeLinkManagerInterface)Naming.lookup("//" + node1.getIpAddress() + "/NodeLinkManager_" + node1.getHostname());
				iFace2 = (NodeLinkManagerInterface)Naming.lookup("//" + node2.getIpAddress() + "/NodeLinkManager_" + node2.getHostname());
				iFace3 = (NodeLinkManagerInterface)Naming.lookup("//" + node3.getIpAddress() + "/NodeLinkManager_" + node3.getHostname());
			}
			catch(Exception e)
			{
				System.out.println("RMI lookup: " + e.getMessage());
			}
			
			//there should still be a loop between the 3 clients
			prevNode1 = iFace1.getPrev();
			nextNode1 = iFace1.getNext();
			
			prevNode2 = iFace2.getPrev();
			nextNode2 = iFace2.getNext();
			
			prevNode3 = iFace3.getPrev();
			nextNode3 = iFace3.getNext();
			
			assert(
					(nextNode1.equals(prevNode3) && nextNode2.equals(prevNode1) && nextNode3.equals(prevNode2))		//1-2-3
					|| (nextNode1.equals(prevNode2) && nextNode3.equals(prevNode1) && nextNode2.equals(prevNode3))	//1-3-2
					): "NodeLinks were not created correctly with 3 nodes";
			
			printDebugInfo("Failure test", "Terminate the node: '" + node2.getHostname() + "' and press 'enter' to continu...");
			commandLineWait();
			
			printDebugInfo("Failure test", "Execute the 'testLinks' command on one of the nodes and press 'enter' to continu...");
			commandLineWait();
			
			//Error should be detected when calling c2 -> 2 client loop should be created
			prevNode1 = iFace1.getPrev();
			nextNode1 = iFace1.getNext();
			
			prevNode3 = iFace3.getPrev();
			nextNode3 = iFace3.getNext();
			
			assert(nextNode1.equals(prevNode1) && nextNode3.equals(prevNode3)): "NodeLinks aren't correct.";
			passed++;
		}
		catch(AssertionError e)
		{
			printDebugInfo("Failure", e.getMessage());
		}
		catch(NullPointerException | RemoteException e) 
		{
			System.err.println("NodeServer exception: "+ e.getMessage());
		}
	}