Index: src/FunctionApproximation/unittests/FunctionArgumentUnitTest.cpp
===================================================================
--- src/FunctionApproximation/unittests/FunctionArgumentUnitTest.cpp	(revision 355af848a519d00e953ce3fa5d65e6236684dc1b)
+++ src/FunctionApproximation/unittests/FunctionArgumentUnitTest.cpp	(revision 355af848a519d00e953ce3fa5d65e6236684dc1b)
@@ -0,0 +1,98 @@
+/*
+ * Project: MoleCuilder
+ * Description: creates and alters molecular systems
+ * Copyright (C)  2012 University of Bonn. All rights reserved.
+ * 
+ *
+ *   This file is part of MoleCuilder.
+ *
+ *    MoleCuilder is free software: you can redistribute it and/or modify
+ *    it under the terms of the GNU General Public License as published by
+ *    the Free Software Foundation, either version 2 of the License, or
+ *    (at your option) any later version.
+ *
+ *    MoleCuilder is distributed in the hope that it will be useful,
+ *    but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *    GNU General Public License for more details.
+ *
+ *    You should have received a copy of the GNU General Public License
+ *    along with MoleCuilder.  If not, see <http://www.gnu.org/licenses/>.
+ */
+
+/*
+ * FunctionArgumentUnitTest.cpp
+ *
+ *  Created on: Oct 16, 2012
+ *      Author: heber
+ */
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+using namespace std;
+
+#include <cppunit/CompilerOutputter.h>
+#include <cppunit/extensions/TestFactoryRegistry.h>
+#include <cppunit/ui/text/TestRunner.h>
+
+#include "FunctionArgumentUnitTest.hpp"
+
+#include <boost/assign.hpp>
+
+#include "CodePatterns/Assert.hpp"
+
+#include "FunctionApproximation/FunctionArgument.hpp"
+#include "Potentials/helpers.hpp"
+
+using namespace boost::assign;
+
+#ifdef HAVE_TESTRUNNER
+#include "UnitTestMain.hpp"
+#endif /*HAVE_TESTRUNNER*/
+
+/********************************************** Test classes **************************************/
+
+// Registers the fixture into the 'registry'
+CPPUNIT_TEST_SUITE_REGISTRATION( FunctionArgumentTest );
+
+
+void FunctionArgumentTest::setUp()
+{
+  // failing asserts should be thrown
+  ASSERT_DO(Assert::Throw);
+
+}
+
+
+void FunctionArgumentTest::tearDown()
+{
+}
+
+/** UnitTest for IndexComparator()
+ */
+void FunctionArgumentTest::IndexComparatorTest()
+{
+  argument_t arg( std::make_pair(1,2), 0. );
+  argument_t otherarg( std::make_pair(1,3), 0. );
+  argument_t anotherarg( std::make_pair(0,1), 0. );
+
+  CPPUNIT_ASSERT( argument_t::IndexComparator(arg, otherarg) );
+  CPPUNIT_ASSERT( !argument_t::IndexComparator(arg, anotherarg) );
+  CPPUNIT_ASSERT( !argument_t::IndexComparator(otherarg, anotherarg) );
+}
+
+/** UnitTest for DistanceComparator()
+ */
+void FunctionArgumentTest::DistanceComparatorTest()
+{
+  argument_t arg( 0.5 );
+  argument_t otherarg( 0.9 );
+  argument_t anotherarg( 1.4 );
+
+  CPPUNIT_ASSERT( argument_t::DistanceComparator(arg, otherarg) );
+  CPPUNIT_ASSERT( argument_t::DistanceComparator(arg, anotherarg) );
+  CPPUNIT_ASSERT( argument_t::DistanceComparator(otherarg, anotherarg) );
+}
Index: src/FunctionApproximation/unittests/FunctionArgumentUnitTest.hpp
===================================================================
--- src/FunctionApproximation/unittests/FunctionArgumentUnitTest.hpp	(revision 355af848a519d00e953ce3fa5d65e6236684dc1b)
+++ src/FunctionApproximation/unittests/FunctionArgumentUnitTest.hpp	(revision 355af848a519d00e953ce3fa5d65e6236684dc1b)
@@ -0,0 +1,37 @@
+/*
+ * FunctionArgumentUnitTest.hpp
+ *
+ *  Created on: Oct 16, 2012
+ *      Author: heber
+ */
+
+#ifndef FUNCTIONARGUMENTUNITTEST_HPP_
+#define FUNCTIONARGUMENTUNITTEST_HPP_
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+
+#include <cppunit/extensions/HelperMacros.h>
+
+/********************************************** Test classes **************************************/
+
+class FunctionArgumentTest : public CppUnit::TestFixture
+{
+    CPPUNIT_TEST_SUITE( FunctionArgumentTest) ;
+    CPPUNIT_TEST ( IndexComparatorTest );
+    CPPUNIT_TEST ( DistanceComparatorTest );
+    CPPUNIT_TEST_SUITE_END();
+
+public:
+      void setUp();
+      void tearDown();
+      void IndexComparatorTest();
+      void DistanceComparatorTest();
+
+private:
+};
+
+#endif /* FUNCTIONARGUMENTUNITTEST_HPP_ */
Index: src/FunctionApproximation/unittests/Makefile.am
===================================================================
--- src/FunctionApproximation/unittests/Makefile.am	(revision 355af848a519d00e953ce3fa5d65e6236684dc1b)
+++ src/FunctionApproximation/unittests/Makefile.am	(revision 355af848a519d00e953ce3fa5d65e6236684dc1b)
@@ -0,0 +1,30 @@
+# PLEASE adhere to the alphabetical ordering in this Makefile!
+# Also indentation by a single tab
+
+FUNCTIONAPPROXIMATIONTESTSSOURCES = \
+	../FunctionApproximation/unittests/FunctionArgumentUnitTest.cpp
+
+FUNCTIONAPPROXIMATIONTESTSHEADERS = \
+	../FunctionApproximation/unittests/FunctionArgumentUnitTest.hpp
+
+FUNCTIONAPPROXIMATIONTESTS = \
+	FunctionArgumentUnitTest
+
+TESTS += $(FUNCTIONAPPROXIMATIONTESTS)
+check_PROGRAMS += $(FUNCTIONAPPROXIMATIONTESTS) 
+noinst_PROGRAMS += $(FUNCTIONAPPROXIMATIONTESTS)
+
+FUNCTIONAPPROXIMATIONLIBS = \
+	../libMolecuilderFunctionApproximation.la \
+	$(top_builddir)/LinearAlgebra/src/LinearAlgebra/libLinearAlgebra.la \
+	${CodePatterns_LIBS} \
+	$(BOOST_SERIALIZATION_LDFLAGS) $(BOOST_SERIALIZATION_LIBS) \
+	$(BOOST_LIB)
+
+FunctionArgumentUnitTest_SOURCES = $(top_srcdir)/src/unittests/UnitTestMain.cpp \
+	../FunctionApproximation/unittests/FunctionArgumentUnitTest.cpp \
+	../FunctionApproximation/unittests/FunctionArgumentUnitTest.hpp
+FunctionArgumentUnitTest_LDADD = ${FUNCTIONAPPROXIMATIONLIBS}
+
+
+#AUTOMAKE_OPTIONS = parallel-tests
