]> git.donarmstrong.com Git - biopieces.git/blobdiff - code_ruby/test/maasha/test_seq.rb
added remove_indels method
[biopieces.git] / code_ruby / test / maasha / test_seq.rb
index 76652981e4349b1ea57e875cdd5c879e37e310d6..a4d47ad203d601a54a5012855c1ca3942976e186 100755 (executable)
@@ -458,6 +458,19 @@ class TestSeq < Test::Unit::TestCase
     assert_equal("ghhhhhg", @entry.qual) 
   end
 
+  def test_Seq_indels_remove_without_qual_returns_correctly
+    @entry.seq  = "A-T.CG~CG"
+    @entry.qual = nil
+    assert_equal("ATCGCG", @entry.indels_remove.seq)
+  end
+
+  def test_Seq_indels_remove_with_qual_returns_correctly
+    @entry.seq  = "A-T.CG~CG"
+    @entry.qual = "a@b@cd@fg"
+    assert_equal("ATCGCG", @entry.indels_remove.seq)
+    assert_equal("abcdfg", @entry.indels_remove.qual)
+  end
+
   def test_Seq_composition_returns_correctly
     @entry.seq = "AAAATTTCCG"
     assert_equal(4, @entry.composition["A"])