package org.yukung.tutorial.junit;

import static org.hamcrest.CoreMatchers.*;
import static org.junit.Assert.*;

import org.junit.After;
import org.junit.Before;
import org.junit.Test;

public class CalculatorTest {

	@Before
	public void setUp() throws Exception {
	}

	@After
	public void tearDown() throws Exception {
	}

	@Test
	public void multiplyで3と4の乗算結果が取得できる() {
		Calculator calc = new Calculator();
		int expected = 12;
		int actual = calc.multiply(3, 4);
		assertThat(actual, is(expected));
	}

}

@@ -502,10 +502,209 @@
 ));%0A%09%7D%0A%0A
+%09@Test%0A%09public void multiply%E3%81%A75%E3%81%A87%E3%81%AE%E4%B9%97%E7%AE%97%E7%B5%90%E6%9E%9C%E3%81%8C%E5%8F%96%E5%BE%97%E3%81%A7%E3%81%8D%E3%82%8B() throws Exception %7B%0A%09%09Calculator calc = new Calculator();%0A%09%09int expected = 12;%0A%09%09int actual = calc.multiply(5, 7);%0A%09%09assertThat(actual, is(expected));%0A%09%7D%0A
 %7D%0A

テストの追加。