[Dbix-class] Testing classes as CPAN distribution?

John Napiorkowski jjn1056 at yahoo.com
Mon Jun 9 18:43:31 BST 2008




--- On Mon, 6/9/08, Zbigniew Lukasiak <zzbbyy at gmail.com> wrote:

> From: Zbigniew Lukasiak <zzbbyy at gmail.com>
> Subject: [Dbix-class] Testing classes as CPAN distribution?
> To: "DBIx::Class user and developer list" <dbix-class at lists.scsys.co.uk>
> Date: Monday, June 9, 2008, 1:20 PM
> Hi,
> 
> When writing some DBIC extensions or other DBIC dependent
> modules it
> is useful to have at hand the full array of possible DBIC
> classes and
> relations.  What do you think about copying part of the
> DBIC testing
> library and releasing it as a CPAN module?

I've actually been slowly working on something like this on the side.  I was thinking it would eventually be something like the way catalyst helpers work, so that you can target an namespace and directory like:

build_dbic_testlibs.pl --namespace 'MyApp' -directory 't/lib'

and you'd get a schema in t/lib with a loader and a bunch of classes.  I was also thinking it could populate default data, etc and then the author could go in and add additional stuff.  Would also be great if it created a default test for you, that way you can check to make sure your custom component didn't blow anything up.

If you care to collaborate we can meet up on IRC and work out some details, if that works for you.  I was orginally also making these test classes as something that's highly documented, that way they could server a dual purpose, both for testing and also as a teaching tool.   My current status with is is I got about half the schema classes I think I need for this to work, as well as a way to quickly deploy to SQLite or another target DB.


--JohnN

> 
> -- 
> Zbigniew Lukasiak
> http://brudnopis.blogspot.com/
> 
> _______________________________________________
> List:
> http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class
> IRC: irc.perl.org#dbix-class
> SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/
> Searchable Archive:
> http://www.grokbase.com/group/dbix-class@lists.rawmode.org


      



More information about the DBIx-Class mailing list