package ru.pravvich;

import org.junit.Test;
import static org.hamcrest.core.Is.is;
import static org.junit.Assert.*;

public class CalculateTest {	
	@Test
	public void wthenSetAdditionThenArgumentAddition() {
			Calculate calc = new Calculate();
			
		    //А как мне указать что мне нужен getResoult записанный из метода add?
			calc.add(2D, 3D);
			double result = calc.getResult(); 						
			assertThat(result, is(5D));
	
	}

}




@@ -244,89 +244,8 @@
 ();%0A
-%09%09%09%0A%09%09    //%D0%90 %D0%BA%D0%B0%D0%BA %D0%BC%D0%BD%D0%B5 %D1%83%D0%BA%D0%B0%D0%B7%D0%B0%D1%82%D1%8C %D1%87%D1%82%D0%BE %D0%BC%D0%BD%D0%B5 %D0%BD%D1%83%D0%B6%D0%B5%D0%BD getResoult %D0%B7%D0%B0%D0%BF%D0%B8%D1%81%D0%B0%D0%BD%D0%BD%D1%8B%D0%B9 %D0%B8%D0%B7 %D0%BC%D0%B5%D1%82%D0%BE%D0%B4%D0%B0 add?%0A
 %09%09%09c
@@ -340,15 +340,642 @@
 ));%0A%09%0A%09%7D
+%0A%09%0A%09@Test%0A%09public void wthenSetSubstractThenArgumentSubstract() %7B%0A%09%09%09Calculate calc = new Calculate();%0A%09%09%09calc.substract(3D, 2D);%0A%09%09%09double result = calc.getResult(); %09%09%09%09%09%09%0A%09%09%09assertThat(result, is(1D));%0A%09%0A%09%7D%0A%09%0A%09@Test%0A%09public void wthenSetMultiplicationThenArgumentMultiplication() %7B%0A%09%09%09Calculate calc = new Calculate();%0A%09%09%09calc.mult(3D, 2D);%0A%09%09%09double result = calc.getResult(); %09%09%09%09%09%09%0A%09%09%09assertThat(result, is(6D));%0A%09%0A%09%7D%09%0A%09%0A%09@Test%0A%09public void wthenSetDivisionThenArgumentDivision() %7B%0A%09%09%09Calculate calc = new Calculate();%0A%09%09%09calc.div(6D, 2D);%0A%09%09%09double result = calc.getResult(); %09%09%09%09%09%09%0A%09%09%09assertThat(result, is(3D));%0A%09%0A%09%7D%09%09
 %0A%0A%7D%0A%0A%0A%0A

add test\java\ru\pravvich\CalculateTest.java