diff --git a/nucleotide-count/Example.cs b/nucleotide-count/Example.cs index 48f9c729f8..4dbd18ddc5 100644 --- a/nucleotide-count/Example.cs +++ b/nucleotide-count/Example.cs @@ -19,19 +19,11 @@ private void InitializeNucleotideCounts(string sequence) public int Count(char nucleotide) { - if (IsUracil(nucleotide)) - return 0; - int count; if (!NucleotideCounts.TryGetValue(nucleotide, out count)) throw new InvalidNucleotideException(); return count; } - - private static bool IsUracil(char nucleotide) - { - return nucleotide == 'U'; - } } public class InvalidNucleotideException : Exception { } diff --git a/nucleotide-count/NucleotideCountTest.cs b/nucleotide-count/NucleotideCountTest.cs index 492bc25a70..0648c76a6e 100644 --- a/nucleotide-count/NucleotideCountTest.cs +++ b/nucleotide-count/NucleotideCountTest.cs @@ -54,14 +54,6 @@ public void Counts_a_nucleotide_only_once() Assert.That(dna.Count('T'), Is.EqualTo(2)); } - [Ignore] - [Test] - public void Has_no_uracil() - { - var dna = new DNA("GGTTGG"); - Assert.That(dna.Count('U'), Is.EqualTo(0)); - } - [Ignore] [Test] public void Validates_nucleotides() @@ -78,4 +70,4 @@ public void Counts_all_nucleotides() var expected = new Dictionary { { 'A', 20 }, { 'T', 21 }, { 'C', 12 }, { 'G', 17 } }; Assert.That(dna.NucleotideCounts, Is.EqualTo(expected)); } -} \ No newline at end of file +}