"You can specify the additional module classes when creating the page
tester."

Howard, could you go into a little more detail here?  I didn't see a
constructor arg or a method on PageTester for specifying additional
modules.

-----Original Message-----
From: Howard Lewis Ship [mailto:[EMAIL PROTECTED] 
Sent: Sunday, May 27, 2007 7:28 PM
To: Tapestry users
Subject: Re: T5: Testing - PageTester reworked... How do I use mock
services now?

It's a good point. What you need to do is define a module that defines
your mock services, and contributes overrides into the Alias or
AliasOverride service configuration, such that your mock services are
used instead of the normal ones.  You can specify the additional module
classes when creating the page tester.

On 5/27/07, Otho <[EMAIL PROTECTED]> wrote:
>
> Hi all!
> I followed the TestNG example with service replacements on the 
> Tapestry home page only to find out that PageTester was reworked and 
> now doesn't support a map with replacements anymore. I was unable to 
> find any documentation in the changelogs or the mailinglist about why 
> this was changed and how to use mock services with a PageTester right 
> now.
>
> Start page depends on a spring service and this doesn't get injected 
> automatically. So if I want to test it I have to somehow inject a Mock

> in there, or did I get something wrong?
>
> Regards,
> Otho
>



--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant Creator and PMC Chair,
Apache Tapestry Creator, Apache HiveMind

Professional Tapestry training, mentoring, support and project work.
http://howardlewisship.com

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

Reply via email to