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.159 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.158 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.157 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.156 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.155 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.154 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.153 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.152 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.151 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.150 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.149 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.148 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.147 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.146 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.145 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.144 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.143 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.142 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.141 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc
trackler-2.2.1.140 tracks/cfml/exercises/space-age/SpaceAgeTest.cfc