public static void runSingleTest( int seed, int times ) { // * Config params for testing List<Universe> uList = new List<Universe>( ); int universeMax = times; // * Run test for a fixed seed while ( uList.Count < universeMax ) { Universe u = new Universe( ); u.run( seed ); uList.Add( u ); } // [] Print results printResult( uList ); lastTest = uList; }
public static void runTest( int count = 30 ) { // * Config params for testing List<Universe> uList = new List<Universe>( ); int universeMax = 30; // * Run test for ( int i = 1; i <= universeMax; i++ ) { Universe u = new Universe( ); uList.Add( u ); u.run( i ); } // [] Print results printResult( uList ); lastTest = uList; }
public static void runFilterTest( int count, int minYear, int maxYear, int minShips, int maxShips ) { // * Config params for testing List<Universe> uList = new List<Universe>( ); int universeMax = 10; // * Run test int seed = 1; while( uList.Count < universeMax ) { Universe u = new Universe( ); u.run( seed ); if ( u.rlt_endYear <= maxYear && u.rlt_endYear >= minYear && u.rlt_shipCount >= minShips && u.rlt_shipCount <= maxShips ) uList.Add( u ); seed++; } // [] Print results printResult( uList ); lastTest = uList; }