From: Jeff M. <cus...@us...> - 2002-09-10 10:40:36
|
Update of /cvsroot/mockobjects/mockobjects-java/src/j2ee/1.3/com/mockobjects/servlet In directory usw-pr-cvs1:/tmp/cvs-serv18187 Modified Files: MockHttpServletRequest.java Log Message: Added patch for getContextPath provided by Chris Nokleberg <ch...@si...> Index: MockHttpServletRequest.java =================================================================== RCS file: /cvsroot/mockobjects/mockobjects-java/src/j2ee/1.3/com/mockobjects/servlet/MockHttpServletRequest.java,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- MockHttpServletRequest.java 27 Aug 2002 16:38:17 -0000 1.8 +++ MockHttpServletRequest.java 10 Sep 2002 10:40:32 -0000 1.9 @@ -21,6 +21,7 @@ private Dictionary myHeaders = new Hashtable(); private HttpSession myHttpSession; private String myContentTypeToReturn; + private String myContextPath; private String myPathInfo; private String myRemoteAddress; private String myRequestURI; @@ -91,8 +92,11 @@ } public String getContextPath() { - notImplemented(); - return null; + return myContextPath; + } + + public void setupGetContextPath(String contextPath) { + myContextPath = contextPath; } public Cookie[] getCookies() { @@ -352,4 +356,4 @@ public Map getParameterMap() { return null; } -} \ No newline at end of file +} |