cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gkossakow...@apache.org
Subject svn commit: r570391 - /cocoon/trunk/core/cocoon-servlet-service/cocoon-servlet-service-impl/src/test/java/org/apache/cocoon/servletservice/ServletServiceContextTest.java
Date Tue, 28 Aug 2007 11:54:17 GMT
Author: gkossakowski
Date: Tue Aug 28 04:54:16 2007
New Revision: 570391

URL: http://svn.apache.org/viewvc?rev=570391&view=rev
Log:
COCOON-2038: Cleanup of tests.

Modified:
    cocoon/trunk/core/cocoon-servlet-service/cocoon-servlet-service-impl/src/test/java/org/apache/cocoon/servletservice/ServletServiceContextTest.java

Modified: cocoon/trunk/core/cocoon-servlet-service/cocoon-servlet-service-impl/src/test/java/org/apache/cocoon/servletservice/ServletServiceContextTest.java
URL: http://svn.apache.org/viewvc/cocoon/trunk/core/cocoon-servlet-service/cocoon-servlet-service-impl/src/test/java/org/apache/cocoon/servletservice/ServletServiceContextTest.java?rev=570391&r1=570390&r2=570391&view=diff
==============================================================================
--- cocoon/trunk/core/cocoon-servlet-service/cocoon-servlet-service-impl/src/test/java/org/apache/cocoon/servletservice/ServletServiceContextTest.java
(original)
+++ cocoon/trunk/core/cocoon-servlet-service/cocoon-servlet-service-impl/src/test/java/org/apache/cocoon/servletservice/ServletServiceContextTest.java
Tue Aug 28 04:54:16 2007
@@ -40,9 +40,11 @@
     private ServletServiceContext mainContext;
     private HttpServlet servletA;
     private HttpServlet servletB;
+    private HttpServlet servletC;
     
     private ServletServiceContext servletAContext;
     private ServletServiceContext servletBContext;
+    private ServletServiceContext servletCContext;
     
     BlockCallHttpServletRequest request;
     BlockCallHttpServletResponse response;
@@ -59,9 +61,10 @@
         request.setMethod("GET");
         response = new BlockCallHttpServletResponse();
         
-        //creating and setting up ServletContexts
+        //creating ServletContexts
         servletAContext = new ServletServiceContext();
-        servletBContext = new ServletServiceContext();        
+        servletBContext = new ServletServiceContext();
+        servletCContext = new ServletServiceContext();
     }
     
     /**
@@ -147,8 +150,6 @@
      * @throws Exception
      */
     public void testContextInServletCalledFromExplicitSuperCall() throws Exception {
-        final ServletServiceContext servletCContext = new ServletServiceContext();
-        
         servletA = new HttpServlet() {
             public ServletConfig getServletConfig() { return new ServletConfigWithContext(servletAContext);
}
 
@@ -169,7 +170,7 @@
             }
         };
         
-        HttpServlet servletC = new HttpServlet() {
+        servletC = new HttpServlet() {
             public ServletConfig getServletConfig() { return new ServletConfigWithContext(servletCContext);
}
             
             protected void service(HttpServletRequest req, HttpServletResponse res) throws
ServletException, IOException {
@@ -209,9 +210,7 @@
      * 
      * @throws Exception
      */
-    public void testtrueObjectOrientedBehaviour() throws Exception {
-        final ServletServiceContext servletCContext = new ServletServiceContext();
-        
+    public void testTrueObjectOrientedBehaviour() throws Exception {
         servletA = new HttpServlet() {
             public ServletConfig getServletConfig() { return new ServletConfigWithContext(servletAContext);
}
 
@@ -232,7 +231,7 @@
             }
         };
         
-        HttpServlet servletC = new HttpServlet() {
+        servletC = new HttpServlet() {
             public ServletConfig getServletConfig() { return new ServletConfigWithContext(servletCContext);
}
             
             protected void service(HttpServletRequest req, HttpServletResponse res) throws
ServletException, IOException {



Mime
View raw message