--- /dev/null
+#include <boost/test/auto_unit_test.hpp>
+
+#include "alg/sequence_location.hpp"
+#include "alg/sequence.hpp"
+
+BOOST_AUTO_TEST_CASE( basic_sequence_location )
+{
+ Sequence s("AAGGCCTT");
+
+ SequenceLocation sl(s, 0, 2);
+
+ BOOST_CHECK_EQUAL( sl.getLeft(), 0 );
+ BOOST_CHECK_EQUAL( sl.getRight(), 2 );
+ BOOST_CHECK_EQUAL( sl.getCount(), 2 );
+
+ sl.setLeft(1);
+ sl.setRight(3);
+
+ BOOST_CHECK_EQUAL( sl.getLeft(), 1 );
+ BOOST_CHECK_EQUAL( sl.getRight(), 3 );
+ BOOST_CHECK_EQUAL( sl.getCount(), 2 );
+}
+
+BOOST_AUTO_TEST_CASE( memory_test )
+{
+ SequenceLocation *sl;
+ // storing references is a bad idea
+ {
+ Sequence s("AAGGCCTT");
+ sl = new SequenceLocation(s, 0, 2);
+ }
+
+ BOOST_CHECK_EQUAL(sl->getSequence(), "AAGGCCTT");
+}