-
-
Notifications
You must be signed in to change notification settings - Fork 690
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rna-transcription: change to object based implementation
See issue #177
- Loading branch information
1 parent
6505d73
commit 7c36665
Showing
2 changed files
with
15 additions
and
8 deletions.
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
exercises/rna-transcription/src/example/java/RnaTranscription.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 14 additions & 7 deletions
21
exercises/rna-transcription/src/test/java/RnaTranscriptionTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,42 +1,49 @@ | ||
import org.junit.Assert; | ||
import org.junit.Test; | ||
import org.junit.Before; | ||
import org.junit.Ignore; | ||
import org.junit.Test; | ||
|
||
public class RnaTranscriptionTest { | ||
|
||
private RnaTranscription rnaTranscription; | ||
|
||
@Before | ||
public void setUp() { | ||
rnaTranscription = new RnaTranscription(); | ||
} | ||
|
||
@Test | ||
public void testRnaTranscriptionOfEmptyDnaIsEmptyRna() { | ||
Assert.assertEquals("", RnaTranscription.ofDna("")); | ||
Assert.assertEquals("", rnaTranscription.ofDna("")); | ||
} | ||
|
||
@Ignore | ||
@Test | ||
public void testRnaTranscriptionOfCytosineIsGuanine() { | ||
Assert.assertEquals("G", RnaTranscription.ofDna("C")); | ||
Assert.assertEquals("G", rnaTranscription.ofDna("C")); | ||
} | ||
|
||
@Ignore | ||
@Test | ||
public void testRnaTranscriptionOfGuanineIsCytosine() { | ||
Assert.assertEquals("C", RnaTranscription.ofDna("G")); | ||
Assert.assertEquals("C", rnaTranscription.ofDna("G")); | ||
} | ||
|
||
@Ignore | ||
@Test | ||
public void testRnaTranscriptionOfThymineIsAdenine() { | ||
Assert.assertEquals("A", RnaTranscription.ofDna("T")); | ||
Assert.assertEquals("A", rnaTranscription.ofDna("T")); | ||
} | ||
|
||
@Ignore | ||
@Test | ||
public void testRnaTranscriptionOfAdenineIsUracil() { | ||
Assert.assertEquals("U", RnaTranscription.ofDna("A")); | ||
Assert.assertEquals("U", rnaTranscription.ofDna("A")); | ||
} | ||
|
||
@Ignore | ||
@Test | ||
public void testRnaTranscription() { | ||
Assert.assertEquals("UGCACCAGAAUU", RnaTranscription.ofDna("ACGTGGTCTTAA")); | ||
Assert.assertEquals("UGCACCAGAAUU", rnaTranscription.ofDna("ACGTGGTCTTAA")); | ||
} | ||
} |