properties.setProperty( PARALLEL_KEY, "classesAndMethods" );
properties.setProperty( THREADCOUNT_KEY, "3" );
// % percentage ratio
properties.setProperty( THREADCOUNTCLASSES_KEY, "34" );
properties.setProperty( THREADCOUNTMETHODS_KEY, "66" );
JUnitCoreParameters params = new JUnitCoreParameters( properties );
Concurrency concurrency = resolveConcurrency( params );
assertFalse( params.isParallelSuites() );
assertTrue( params.isParallelClasses() );
assertTrue( params.isParallelMethod() );
assertThat( concurrency.capacity, is( 3 * cpu ) );
assertThat( concurrency.suites, is( 0 ) );
int concurrentClasses = (int) ( 0.34d * concurrency.capacity );
assertThat( concurrency.classes, is( concurrentClasses ) );
assertThat( concurrency.methods, is( concurrency.capacity - concurrentClasses ) );