Преглед изворни кода

rna-transcription: rename "ofDna" with "transcribe"

Logan Stucki пре 9 година
родитељ
комит
7aa799831b

+ 1
- 1
exercises/rna-transcription/src/example/java/RnaTranscription.java Прегледај датотеку

@@ -1,6 +1,6 @@
1 1
 public class RnaTranscription {
2 2
 
3
-    public String ofDna(String strand) {
3
+    public String transcribe(String strand) {
4 4
         StringBuilder sb = new StringBuilder();
5 5
         for (char c : strand.toCharArray()) {
6 6
             switch (c) {

+ 1
- 1
exercises/rna-transcription/src/main/java/RnaTranscription.java Прегледај датотеку

@@ -1,5 +1,5 @@
1 1
 public class RnaTranscription {
2
-    public String ofDna(String dnaString) {
2
+    public String transcribe(String dnaString) {
3 3
         throw new UnsupportedOperationException("Method has not been implemented yet.");
4 4
     }
5 5
 }

+ 6
- 6
exercises/rna-transcription/src/test/java/RnaTranscriptionTest.java Прегледај датотеку

@@ -14,36 +14,36 @@ public class RnaTranscriptionTest {
14 14
 
15 15
     @Test
16 16
     public void testRnaTranscriptionOfEmptyDnaIsEmptyRna() {
17
-        Assert.assertEquals("", rnaTranscription.ofDna(""));
17
+        Assert.assertEquals("", rnaTranscription.transcribe(""));
18 18
     }
19 19
 
20 20
     @Ignore("Remove to run test")
21 21
     @Test
22 22
     public void testRnaTranscriptionOfCytosineIsGuanine() {
23
-        Assert.assertEquals("G", rnaTranscription.ofDna("C"));
23
+        Assert.assertEquals("G", rnaTranscription.transcribe("C"));
24 24
     }
25 25
 
26 26
     @Ignore("Remove to run test")
27 27
     @Test
28 28
     public void testRnaTranscriptionOfGuanineIsCytosine() {
29
-        Assert.assertEquals("C", rnaTranscription.ofDna("G"));
29
+        Assert.assertEquals("C", rnaTranscription.transcribe("G"));
30 30
     }
31 31
 
32 32
     @Ignore("Remove to run test")
33 33
     @Test
34 34
     public void testRnaTranscriptionOfThymineIsAdenine() {
35
-        Assert.assertEquals("A", rnaTranscription.ofDna("T"));
35
+        Assert.assertEquals("A", rnaTranscription.transcribe("T"));
36 36
     }
37 37
 
38 38
     @Ignore("Remove to run test")
39 39
     @Test
40 40
     public void testRnaTranscriptionOfAdenineIsUracil() {
41
-        Assert.assertEquals("U", rnaTranscription.ofDna("A"));
41
+        Assert.assertEquals("U", rnaTranscription.transcribe("A"));
42 42
     }
43 43
 
44 44
     @Ignore("Remove to run test")
45 45
     @Test
46 46
     public void testRnaTranscription() {
47
-        Assert.assertEquals("UGCACCAGAAUU", rnaTranscription.ofDna("ACGTGGTCTTAA"));
47
+        Assert.assertEquals("UGCACCAGAAUU", rnaTranscription.transcribe("ACGTGGTCTTAA"));
48 48
     }
49 49
 }