Factorial { public double calcFactorial(){ double result = 1; for(int index = 1; index <= num; index++){ result *=index; } return result; } Factorial(String num); double calcFactorial(); void print(); static void main(String[] args);  }
@Test public void whenlittleNumFactorial(){ Factorial fc = new Factorial("5");; double result = fc.calcFactorial(); double control = 120; Assert.assertThat(result,is(control)); }