KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > servletunit > struts > tests > TestGetMockObjects


1 package servletunit.struts.tests;
2
3 import servletunit.struts.MockStrutsTestCase;
4 import servletunit.HttpServletRequestSimulator;
5 import servletunit.HttpServletResponseSimulator;
6
7 import java.security.Principal JavaDoc;
8
9 /**
10  * Created by IntelliJ IDEA.
11  * User: deryl
12  * Date: May 21, 2003
13  * Time: 2:25:53 PM
14  * To change this template use Options | File Templates.
15  */

16 public class TestGetMockObjects extends MockStrutsTestCase {
17
18     public TestGetMockObjects(String JavaDoc testName) {
19         super(testName);
20     }
21
22     public void testGetMockObjects() {
23         HttpServletRequestSimulator request = this.getMockRequest();
24         request.setUserRole("foo");
25         HttpServletResponseSimulator response = this.getMockResponse();
26         response.getStatusCode();
27     }
28 }
29
Popular Tags