Sha256: 61f5bf05f8ed19fe2b91a4e8ae2d77b3a3f8adfdfcf3bfa2760499b39587a1a3

Contents?: true

Size: 1.15 KB

Versions: 72

Compression:

Stored size: 1.15 KB

Contents

component extends="testbox.system.BaseSpec" {

	function beforeAll(){
	  SUT = createObject( 'RnaTranscription' );
	}

	function run(){
	
		describe( "My RnaTranscription class", function(){			

			it( 'RNA complement of cytosine is guanine', function(){
				expect( SUT.toRna( dna='C' ) ).toBe( 'G' );
			});

			it( 'RNA complement of guanine is cytosine', function(){
				expect( SUT.toRna( dna='G' ) ).toBe( 'C' );
			});

			it( 'RNA complement of thymine is adenine', function(){
				expect( SUT.toRna( dna='T' ) ).toBe( 'A' );
			});

			it( 'RNA complement of adenine is uracil', function(){
				expect( SUT.toRna( dna='A' ) ).toBe( 'U' );
			});

			it( 'RNA complement', function(){
				expect( SUT.toRna( dna='ACGTGGTCTTAA' ) ).toBe( 'UGCACCAGAAUU' );
			});

			it( 'correctly handles invalid input (RNA instead of DNA)', function(){
				expect( SUT.toRna( dna='U' ) ).toBeNull();
			});

			it( 'correctly handles completely invalid DNA input', function(){
				expect( SUT.toRna( dna='XXX' ) ).toBeNull();
			});

			it( 'correctly handles partially invalid DNA input', function(){
				expect( SUT.toRna( dna='ACGTXXXCTTAA' ) ).toBeNull();
			});

		});
		
	}
 
}

Version data entries

72 entries across 71 versions & 1 rubygems

Version Path
trackler-2.2.1.44 tracks/cfml/exercises/rna-transcription/RnaTranscriptionTest.cfc
trackler-2.2.1.43 tracks/cfml/exercises/rna-transcription/RnaTranscriptionTest.cfc
trackler-2.2.1.42 tracks/cfml/exercises/rna-transcription/RnaTranscriptionTest.cfc
trackler-2.2.1.41 tracks/coldfusion/exercises/rna-transcription/RnaTranscriptionTest.cfc
trackler-2.2.1.41 tracks/cfml/exercises/rna-transcription/RnaTranscriptionTest.cfc
trackler-2.2.1.40 tracks/coldfusion/exercises/rna-transcription/RnaTranscriptionTest.cfc
trackler-2.2.1.39 tracks/coldfusion/exercises/rna-transcription/RnaTranscriptionTest.cfc
trackler-2.2.1.38 tracks/coldfusion/exercises/rna-transcription/RnaTranscriptionTest.cfc
trackler-2.2.1.37 tracks/coldfusion/exercises/rna-transcription/RnaTranscriptionTest.cfc
trackler-2.2.1.36 tracks/coldfusion/exercises/rna-transcription/RnaTranscriptionTest.cfc
trackler-2.2.1.35 tracks/coldfusion/exercises/rna-transcription/RnaTranscriptionTest.cfc
trackler-2.2.1.34 tracks/coldfusion/exercises/rna-transcription/RnaTranscriptionTest.cfc