+ test "#<< without qual returns correctly" do
+ @entry.seq = "atcg"
+ @entry << Seq.new("test", "ATCG")
+ assert_equal("atcgATCG", @entry.seq)
+ end
+
+ test "#<< with qual returns correctly" do
+ @entry.seq = "atcg"
+ @entry.type = :dna
+ @entry.qual = "HHHH"
+ @entry << Seq.new("test", "ATCG", :dna, "IIII")
+ assert_equal("atcgATCG", @entry.seq)
+ assert_equal("HHHHIIII", @entry.qual)
+ end
+
+ test "#[] with qual returns correctly" do
+ entry = Seq.new("test", "atcg", :dna, "FGHI")
+
+ e = entry[2]
+
+ assert_equal("test", e.seq_name)
+ assert_equal("c", e.seq)
+ assert_equal(:dna, e.type)
+ assert_equal("H", e.qual)
+ assert_equal("atcg", entry.seq)
+ assert_equal("FGHI", entry.qual)
+ end
+
+ test "#[] without qual returns correctly" do
+ entry = Seq.new("test", "atcg")
+
+ e = entry[2]
+
+ assert_equal("test", e.seq_name)
+ assert_equal("c", e.seq)
+ assert_nil(e.qual)
+ assert_equal("atcg", entry.seq)
+ end
+
+ test "[]= with qual returns correctly" do
+ entry = Seq.new("test", "atcg", :dna, "FGHI")
+
+ entry[0] = Seq.new("foo", "T", :dna, "I")
+
+ assert_equal("test", entry.seq_name)
+ assert_equal("Ttcg", entry.seq)
+ assert_equal(:dna, entry.type)
+ assert_equal("IGHI", entry.qual)
+ end
+
+ test "[]= without qual returns correctly" do
+ entry = Seq.new("test", "atcg")
+
+ entry[0] = Seq.new("foo", "T")
+
+ assert_equal("test", entry.seq_name)
+ assert_equal("Ttcg", entry.seq)
+ end
+
+ test "#subseq with start < 0 raises" do