Re: Webtesting using SimpleTest: How to reset database?

2011-02-24 Thread Joshua Muheim
I managed to work out a solution for this, and I released it as a
library so everyone can use it. I've written in my blog about it.

- Why web tests using the development database are a bad thing:
http://josh.ch/wordpress/?p=8
- Finally: use fixtures with your CakePHP web tests!:
http://josh.ch/wordpress/?p=71

I hope somebody else will find this useful. :-) Please leave a message
if you try it... I'm happy to optimize it further.

On Mon, Sep 6, 2010 at 2:30 PM, Joshua Muheim  wrote:
> Thank you, but this looks like an article that only tells how to use
> fixtures with unit (model) tests. I need this kind of stuff for web
> (view) tests...
>

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


Re: Webtesting using SimpleTest: How to reset database?

2010-09-06 Thread Joshua Muheim
Thank you, but this looks like an article that only tells how to use
fixtures with unit (model) tests. I need this kind of stuff for web
(view) tests...

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Re: Webtesting using SimpleTest: How to reset database?

2010-09-06 Thread Maurits van der Schee

Hi,

Have you read this?

http://bakery.cakephp.org/articles/view/testing-models-with-cakephp-1-2-test-suite

It seems to explain how to use fixtures.

Regards,

Maurits

On 09/06/2010 09:01 AM, psybear83 wrote:

So I'm the only one who needs such functionality? Does CakePHP simply
ignore this great functionality in Rails, or does it offer in a
different way or paradigm?

I guess for the sake of simplicity I will just write a small script
which deletes all tables when starting the tests and inserts some
basic data into it... Not beautiful, but it will be enough for my
purposes.

On 2 Sep., 15:25, psybear83  wrote:

Hi all

 From Ruby on Rails I know web testing, and there it is really great.
But sadly I see that CakePHP offers only some basic web testing by
integrating SimpleTest and not enhancing it.

So is there any way to reset my database tables when starting my test
suite? Or even to insert some startup data (fixtures)? Without this
functionality web testing for CakePHP seems really weak to me...

Thank you.
Josh


Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en




Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Re: Webtesting using SimpleTest: How to reset database?

2010-09-06 Thread psybear83
So I'm the only one who needs such functionality? Does CakePHP simply
ignore this great functionality in Rails, or does it offer in a
different way or paradigm?

I guess for the sake of simplicity I will just write a small script
which deletes all tables when starting the tests and inserts some
basic data into it... Not beautiful, but it will be enough for my
purposes.

On 2 Sep., 15:25, psybear83  wrote:
> Hi all
>
> From Ruby on Rails I know web testing, and there it is really great.
> But sadly I see that CakePHP offers only some basic web testing by
> integrating SimpleTest and not enhancing it.
>
> So is there any way to reset my database tables when starting my test
> suite? Or even to insert some startup data (fixtures)? Without this
> functionality web testing for CakePHP seems really weak to me...
>
> Thank you.
> Josh

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Webtesting using SimpleTest: How to reset database?

2010-09-02 Thread psybear83
Hi all

>From Ruby on Rails I know web testing, and there it is really great.
But sadly I see that CakePHP offers only some basic web testing by
integrating SimpleTest and not enhancing it.

So is there any way to reset my database tables when starting my test
suite? Or even to insert some startup data (fixtures)? Without this
functionality web testing for CakePHP seems really weak to me...

Thank you.
Josh

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en