RE: unit testing when application level scoping used

2003-12-29 Thread Shapira, Yoav
Howdy, Cactus works beautifully with regards to servlet context and general environment setup. Should I instantiate a bean with session scope that is expected to be present? Yes, you should instantiate it and place it in the session/application context as needed by your webapp. Another

RE: unit testing when application level scoping used

2003-12-24 Thread James Black
-Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Monday, December 22, 2003 10:03 AM To: Tomcat Users List Subject: RE: unit testing when application level scoping used Cactus works beautifully with regards to servlet context and general environment setup

re: unit testing when application level scoping used

2003-12-22 Thread James Black
Hello, I am trying to write a unit test for an application I didn't write. There are classes in the classes directory I want to test directly. The problem is that the application uses application and session scoping for some of the classes, so they can reference the instance without having

RE: unit testing when application level scoping used

2003-12-22 Thread Shapira, Yoav
Subject: re: unit testing when application level scoping used Hello, I am trying to write a unit test for an application I didn't write. There are classes in the classes directory I want to test directly. The problem is that the application uses application and session scoping for some

Re: unit testing when application level scoping used

2003-12-22 Thread James Black
Shapira, Yoav wrote: You can use MockObjects for this type of thing, assuming that you mean the ServletContext and similar scopes. We are using a commercial application that is buggy. I am trying to test it to see if a new version is better or not than the current version, but I can't test

RE: unit testing when application level scoping used

2003-12-22 Thread Shapira, Yoav
Howdy, When this is done, will cactus work, or will I need to write my own jsp page, instantiate the classes needed myself, then run the unit test, so that everything is set up for it? I have never thought of the difficulty of unit testing when using servlet contexts. It is indeed a