Skip to content

Commit f092245

Browse files
authored
Added some tests to the longestDinuc to cover more edge cases (#1007)
1 parent e780087 commit f092245

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/test/scala/com/fulcrumgenomics/util/SequencesTest.scala

+9
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,15 @@ class SequencesTest extends UnitSpec {
7979
Sequences.longestDinuc("AGTGTGT") shouldBe OffsetAndLength(1, 6)
8080
Sequences.longestDinuc("GGGGGGGG") shouldBe OffsetAndLength(0, 8)
8181
Sequences.longestDinuc("AGCGtagCGCGCgcGCTCTCTatCGCGCA") shouldBe OffsetAndLength(6, 10)
82+
Sequences.longestDinuc("ACACACTCTCTCT") shouldBe OffsetAndLength(5, 8)
83+
Sequences.longestDinuc("") shouldBe OffsetAndLength(0, 0)
84+
Sequences.longestDinuc("ccgTATGC") shouldBe OffsetAndLength(0, 2)
85+
Sequences.longestDinuc("ATATCC") shouldBe OffsetAndLength(0, 4)
86+
Sequences.longestDinuc("CCATATCC") shouldBe OffsetAndLength(2, 4)
87+
Sequences.longestDinuc("ATAC") shouldBe OffsetAndLength(0, 2)
88+
Sequences.longestDinuc("AACC") shouldBe OffsetAndLength(0, 2)
89+
Sequences.longestDinuc("ACGTAAAAAATT") shouldBe OffsetAndLength(4, 6)
90+
Sequences.longestDinuc("ATAT") shouldBe OffsetAndLength(0, 4)
8291
}
8392

8493
"Sequences.complement" should "return the complement of sequences" in {

0 commit comments

Comments
 (0)