X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Fadmin%2F03data.t;h=872b1cf74cd5dd7d5285b2a634f3fafae5477e02;hb=68de943862f06cabd397d2e74d12cd9cdc999779;hp=8251be1a2a2457902f28a83d25dbe4596037a54d;hpb=dafa32f9c243841283a1966476cdfe9300d5c536;p=dbsrgits%2FDBIx-Class.git diff --git a/t/admin/03data.t b/t/admin/03data.t index 8251be1..872b1cf 100644 --- a/t/admin/03data.t +++ b/t/admin/03data.t @@ -1,36 +1,19 @@ -# -#=============================================================================== -# -# FILE: 03sql.t -# -# DESCRIPTION: test sql manipulation funtions -# -# FILES: --- -# BUGS: --- -# NOTES: --- -# AUTHOR: Gordon Irving (), -# VERSION: 1.0 -# CREATED: 12/12/09 12:44:57 GMT -# REVISION: --- -#=============================================================================== - use strict; use warnings; use Test::More; - use Test::Exception; -use Test::Deep; BEGIN { - eval "use DBIx::Class::Admin"; - plan skip_all => "Deps not installed: $@" if $@; + require DBIx::Class; + plan skip_all => 'Test needs ' . DBIx::Class::Optional::Dependencies->req_missing_for('admin') + unless DBIx::Class::Optional::Dependencies->req_ok_for('admin'); } use lib 't/lib'; use DBICTest; -use ok 'DBIx::Class::Admin'; +use_ok 'DBIx::Class::Admin'; { # test data maniplulation functions @@ -64,12 +47,12 @@ use ok 'DBIx::Class::Admin'; my $expected_data = [ [$employee->result_source->columns() ], - [1,1,undef,undef,undef,'Trout'], - [2,2,undef,undef,undef,'Aran'] + [1,1,undef,undef,undef,'Trout',undef], + [2,2,undef,undef,undef,'Aran',undef] ]; my $data; lives_ok { $data = $admin->select('Employee')} 'can retrive data from database'; - cmp_deeply($data, $expected_data, 'DB matches whats expected'); + is_deeply($data, $expected_data, 'DB matches whats expected'); $admin->delete('Employee', {name=>'Trout'}); my $del_rs = $employees->search({name => 'Trout'});