Adding test code from encog-java-core