Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion nucleotide-count/example.java
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public int count(char base) {
}

private static boolean isCountable(char base) {
final String COUNTABLE_NUCLEOTIDES = "ACGTU";
final String COUNTABLE_NUCLEOTIDES = "ACGT";
return COUNTABLE_NUCLEOTIDES.indexOf(base) == -1;
}

Expand Down
10 changes: 2 additions & 8 deletions nucleotide-count/src/test/java/NucleotideTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -52,15 +52,9 @@ public void testCountsANucleotideOnlyOnce() {
}

@Test
public void testDnaHasNoUracil() {
DNA dna = new DNA("CGATTGGG");
assertThat(dna.count('U')).isEqualTo(0);
}

@Test
public void testDnaCountsDoNotChangeAfterCountingUracil() {
public void testDnaCountsDoNotChangeAfterCountingAdenosine() {
DNA dna = new DNA("GATTACA");
dna.count('U');
dna.count('A');
assertThat(dna.nucleotideCounts()).hasSize(4).contains(
entry('A', 3),
entry('C', 1),
Expand Down