01: package servletunit.struts.tests.cactus;
02:
03: import servletunit.struts.CactusStrutsTestCase;
04:
05: import java.util.Map;
06:
07: /**
08: * Created by IntelliJ IDEA.
09: * User: deryl
10: * Date: Apr 12, 2003
11: * Time: 8:53:11 PM
12: * To change this template use Options | File Templates.
13: */
14: public class TestClearParameters extends CactusStrutsTestCase {
15:
16: public TestClearParameters(String testName) {
17: super (testName);
18: }
19:
20: public void testClearParameters() {
21: addRequestParameter("foo", "bar");
22: addRequestParameter("hi", "there");
23: assertEquals("bar", getRequest().getParameter("foo"));
24: assertEquals("there", getRequest().getParameter("hi"));
25: clearRequestParameters();
26: assertNull(getRequest().getParameter("foo"));
27: assertNull(getRequest().getParameter("hi"));
28: }
29:
30: }
|