package ru.job4j.loop;

import org.junit.Test;

import static org.hamcrest.core.Is.is;
import static org.junit.Assert.assertThat;
/**
* Package for factorial test.
*
* @author Evgeniy Vinnitskiy (mailto:report-2k8@yandex.ru)
* @version $1.0$
* @since 11.05.2017
*/
public class FactorialTest {
	/**
	* Test factorial 5.
	*/
    @Test
    public void whenCalculateFactorialForFiveThenOneHundreedTwenty() {
       Factorial factorial = new Factorial();
	   factorial.calc(5);
	   int result = factorial.calc();
       int expected = 120;
       assertThat(result, is(expected));
    }
	/**
	* Test factorial 0.
	*/
    @Test
    public void whenCalculateFactorialForZeroThenOne() {
       Factorial factorial = new Factorial();
	   factorial.calc(0);
	   int result = factorial.calc();
       int expected = 1;
       assertThat(result, is(expected));
    }
}
@@ -448,31 +448,8 @@
 ();%0A
-%09   factorial.calc(5);%0A
 %09   
@@ -468,32 +468,33 @@
  factorial.calc(
+5
 );%0A       int ex
@@ -701,31 +701,8 @@
 ();%0A
-%09   factorial.calc(0);%0A
 %09   
@@ -729,16 +729,17 @@
 al.calc(
+0
 );%0A     

task 193