Skip to content

Instantly share code, notes, and snippets.

@miya2000
Created November 1, 2010 13:44
Show Gist options
  • Select an option

  • Save miya2000/658190 to your computer and use it in GitHub Desktop.

Select an option

Save miya2000/658190 to your computer and use it in GitHub Desktop.
package doltengtest.action;
import static org.hamcrest.CoreMatchers.*;
import static org.junit.Assert.assertThat;
import javax.annotation.Resource;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.seasar.framework.mock.servlet.MockHttpServletResponse;
import org.seasar.framework.unit.Seasar2;
@RunWith(Seasar2.class)
public class IndexActionTest {
@Resource
MockHttpServletResponse response;
@Test
public void jsonTest() throws Exception {
IndexAction action = new IndexAction();
action.aaa();
String json = response.getResponseString();
assertThat(json, is("{}"));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment