Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister

Re: Testing TT and CDBI under Catalyst

by Corion (Pope)
on Jun 27, 2005 at 13:44 UTC ( #470265=note: print w/replies, xml ) Need Help??

in reply to Testing TT and CDBI under Catalyst

If you have any non-trivial SQL in your cdbi classes, I would test that against a predefined database (SQLite makes creating test databases easy). Any invariants of your non-stock constructors or set_sql queries fall under that.

I don't know what framework you already have for verifying/testing your created HTML, but I would go with something like Test::WWW::Mechanize or Test::HTML::Content (which really lacks functionality I admit) to see that the correct output gets created. This testing of the templates is more an end-to-end test though and not a test of the single snippets, but maybe you can create some stripped-down templates that leave out all the "uninteresting" fluff. Indeed, supplying an alternative configuration/template directory might be enough already for your different tests.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://470265]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (2)
As of 2020-02-24 00:15 GMT
Find Nodes?
    Voting Booth?
    What numbers are you going to focus on primarily in 2020?

    Results (104 votes). Check out past polls.