Testify and activation context problems

View: New views
4 Messages — Rating Filter:   Alert me  

Testify and activation context problems

by Mats Henricson-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi!

I use Testify to smoke test our pages, and currently I have
problems with a non-empty onActivate() function:

    public Object onActivate(Long id) {
        // ...
    }

What do I need to mock to get this onActivate() function to
be called?

Mats

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@...
For additional commands, e-mail: users-help@...


Re: Testify and activation context problems

by Angelo Chen :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

I attempted to do some page/component testings with PageTester, finally gave up, lately tried again with Testify, and gave up as well, following the tutorials, it works, but when trying to apply the test to an existing project, can not make it work, probably we need some more tutorials to make Testify works, any ideas that you can share regarding page/component testing? I'm now back to test only services.

Angelo

Mats Henricson-2 wrote:
Hi!

I use Testify to smoke test our pages, and currently I have
problems with a non-empty onActivate() function:

    public Object onActivate(Long id) {
        // ...
    }

What do I need to mock to get this onActivate() function to
be called?

Mats

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org

Re: Testify and activation context problems

by Paul Field-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi Mats,

> I use Testify to smoke test our pages, and currently I have
> problems with a non-empty onActivate() function:
>
>     public Object onActivate(Long id) {
>         // ...
>     }
>
> What do I need to mock to get this onActivate() function to
> be called?

To get the onActivate called, you need to have the id in the URL that you
render. For example:
tester.renderPage("mypage/1234");   // 1234 is the id

Based on your other email, I think that means you need to write a smarter
getPagePath(page) method to add parameters where appropriate.

Paul




---

This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and delete this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.

Please refer to http://www.db.com/en/content/eu_disclosures.htm for additional EU corporate and regulatory disclosures.

Re: Testify and activation context problems

by Paul Field-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi Angelo,

> I attempted to do some page/component testings with PageTester, finally
gave
> up, lately tried again with Testify, and gave up as well, following the
> tutorials, it works, but when trying to apply the test to an existing
> project, can not make it work, probably we need some more tutorials to
make
> Testify works, any ideas that you can share regarding page/component
> testing? I'm now back to test only services.

Could you be a bit more specific about what's not working with your
existing project?

I saw some of your earlier emails, although it looked like you managed to
solve your issues - but now I'm back from holiday I can help with anything
you're still stuck on.

Paul





---

This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and delete this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.

Please refer to http://www.db.com/en/content/eu_disclosures.htm for additional EU corporate and regulatory disclosures.