Sha256: 564521aea970841e28dde49d4a3e1ed27822bb49e037b969cf412ddde7bcb2ea

Contents?: true

Size: 1.15 KB

Versions: 146

Compression:

Stored size: 1.15 KB

Contents

component extends="testbox.system.BaseSpec" {

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

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

			it( 'age on Earth', function(){
				expect( SUT.age( planet='Earth', seconds='1000000000' ) ).toBe( '31.69' );
			});

			it( 'age on Mercury', function(){
				expect( SUT.age( planet='Mercury', seconds='2134835688' ) ).toBe( '280.88' );
			});

			it( 'age on Venus', function(){
				expect( SUT.age( planet='Venus', seconds='189839836' ) ).toBe( '9.78' );
			});

			it( 'age on Mars', function(){
				expect( SUT.age( planet='Mars', seconds='2329871239' ) ).toBe( '39.25' );
			});

			it( 'age on Jupiter', function(){
				expect( SUT.age( planet='Jupiter', seconds='901876382' ) ).toBe( '2.41' );
			});

			it( 'age on Saturn', function(){
				expect( SUT.age( planet='Saturn', seconds='3000000000' ) ).toBe( '3.23' );
			});

			it( 'age on Uranus', function(){
				expect( SUT.age( planet='Uranus', seconds='3210123456' ) ).toBe( '1.21' );
			});

			it( 'age on Neptune', function(){
				expect( SUT.age( planet='Neptune', seconds='8210123456' ) ).toBe( '1.58' );
			});

		});
		
	}
 
}

Version data entries

146 entries across 145 versions & 1 rubygems

Version Path
trackler-2.2.1.139 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.138 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.137 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.136 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.135 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.134 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.133 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.132 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.131 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.130 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.129 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.128 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.127 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.126 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.125 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.124 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.123 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.122 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.121 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.120 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc