Skip to content

Instantly share code, notes, and snippets.

@siguremon
Created March 2, 2012 20:59
Show Gist options
  • Save siguremon/1961352 to your computer and use it in GitHub Desktop.
Save siguremon/1961352 to your computer and use it in GitHub Desktop.
Calcクラスに対するテストクラス
package net.siguremon.sample.junit;
import static org.junit.Assert.*;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
public class CalcTest {
@Before
public void setUp() throws Exception {
}
@After
public void tearDown() throws Exception {
}
@Test
public void testSum() {
assertEquals(3, new Calc().sum(1, 2));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment