diff --git a/exercises/rna-transcription/src/example/java/RnaTranscription.java b/exercises/rna-transcription/src/example/java/RnaTranscription.java index 150aa9e9d..1ae632679 100644 --- a/exercises/rna-transcription/src/example/java/RnaTranscription.java +++ b/exercises/rna-transcription/src/example/java/RnaTranscription.java @@ -1,8 +1,8 @@ public class RnaTranscription { - public String ofDna(String strand) { + public String transcribe(String dnaStrand) { StringBuilder sb = new StringBuilder(); - for (char c : strand.toCharArray()) { + for (char c : dnaStrand.toCharArray()) { switch (c) { case 'A': sb.append('U'); diff --git a/exercises/rna-transcription/src/main/java/RnaTranscription.java b/exercises/rna-transcription/src/main/java/RnaTranscription.java index a447ae0e2..0524c7661 100644 --- a/exercises/rna-transcription/src/main/java/RnaTranscription.java +++ b/exercises/rna-transcription/src/main/java/RnaTranscription.java @@ -1,5 +1,5 @@ public class RnaTranscription { - public String ofDna(String dnaString) { + public String transcribe(String dnaStrand) { throw new UnsupportedOperationException("Method has not been implemented yet."); } } \ No newline at end of file diff --git a/exercises/rna-transcription/src/test/java/RnaTranscriptionTest.java b/exercises/rna-transcription/src/test/java/RnaTranscriptionTest.java index 6b2dfc8a0..a409210b4 100644 --- a/exercises/rna-transcription/src/test/java/RnaTranscriptionTest.java +++ b/exercises/rna-transcription/src/test/java/RnaTranscriptionTest.java @@ -14,36 +14,36 @@ public void setUp() { @Test public void testRnaTranscriptionOfEmptyDnaIsEmptyRna() { - Assert.assertEquals("", rnaTranscription.ofDna("")); + Assert.assertEquals("", rnaTranscription.transcribe("")); } @Ignore("Remove to run test") @Test public void testRnaTranscriptionOfCytosineIsGuanine() { - Assert.assertEquals("G", rnaTranscription.ofDna("C")); + Assert.assertEquals("G", rnaTranscription.transcribe("C")); } @Ignore("Remove to run test") @Test public void testRnaTranscriptionOfGuanineIsCytosine() { - Assert.assertEquals("C", rnaTranscription.ofDna("G")); + Assert.assertEquals("C", rnaTranscription.transcribe("G")); } @Ignore("Remove to run test") @Test public void testRnaTranscriptionOfThymineIsAdenine() { - Assert.assertEquals("A", rnaTranscription.ofDna("T")); + Assert.assertEquals("A", rnaTranscription.transcribe("T")); } @Ignore("Remove to run test") @Test public void testRnaTranscriptionOfAdenineIsUracil() { - Assert.assertEquals("U", rnaTranscription.ofDna("A")); + Assert.assertEquals("U", rnaTranscription.transcribe("A")); } @Ignore("Remove to run test") @Test public void testRnaTranscription() { - Assert.assertEquals("UGCACCAGAAUU", rnaTranscription.ofDna("ACGTGGTCTTAA")); + Assert.assertEquals("UGCACCAGAAUU", rnaTranscription.transcribe("ACGTGGTCTTAA")); } }