Jeff,

I followed the instructions at the link provided below and it worked
great!
Basically just pasted the code from the example:

    static
    {
        try
        {
           config = new TurbineConfig( "../webapp",
"/WEB-INF/conf/TurbineResources.properties");
           config.init();
        }
        catch (Exception e)
        {
            fail(StringUtils.stackTrace(e));
        }
    }

Thanks,

David

> -----Original Message-----
> From: Brekke, Jeff [mailto:[EMAIL PROTECTED]] 
> Sent: Friday, March 22, 2002 6:57 PM
> To: 'David Sean Taylor '; ''Turbine Users List' '
> Subject: RE: Testing a turbine service
> 
> 
>  
> The singletons in t2 are going to be difficult to test in 
> isolation.  Cactus is your best bet, especially if you want 
> to test real servlet intraction. If you can get away with 
> starting Turbine standalone, it works also ( 
> http://jakarta.apache.org/turbine/tdk/application-testing.html
>  ).  I've used this to get turbine going for tests that use 
> resources, connection pool, pull, and globalcache services.
> 
> jb
> 
> -----Original Message-----
> From: David Sean Taylor
> To: 'Turbine Users List'
> Sent: 3/22/02 6:02 PM
> Subject: RE: Testing a turbine service
> 
> 
> > -----Original Message-----
> > From: Jason van Zyl [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, March 22, 2002 9:34 AM
> > To: Turbine Users List
> > Subject: Re: Testing a turbine service
> > 
> > 
> > On Fri, 2002-03-22 at 12:53, David Sean Taylor wrote:
> > > I would like to run junit tests (not cactus) that test my services
> > > (they are Turbine services). How can I bootstrap the bare minimal 
> > > Turbine services in order to run my tests?
> > > Can this be done without a TR.p
> > > 
> > > Im using Turbine 2.2 b1
> > 
> > If you look at the dvsl service test in fulcrum you'll see
> > that you don't even need to start the service framework to 
> > test the service itself. Just instantiate the implementation 
> > class in your harness and run the tests. The dvsl test is a 
> > good example.
> >  
> 
> The code being tested calls other TurbineServices via the 
> usual service
> broker method.
> Ive been trying to find a way to get this to work, but I 
> don't think its
> possible.
> It appears that this particular service requires to be initialized on
> the init(ServletConfig) signature.
> And that TurbineServices requires that several primary services are
> loaded.
> 
> Perhaps it will be better to run it as a Cactus test case
> 
> 
> 
> --
> To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
> 
> --
> To unsubscribe, e-mail:   
> <mailto:turbine-user-> [EMAIL PROTECTED]>
> For 
> additional commands, 
> e-mail: <mailto:[EMAIL PROTECTED]>
> 
> 



--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to