Massive cleanup of DateTime test dependencies, other interim
[dbsrgits/DBIx-Class.git] / t / admin / 03data.t
index 3bbdcc5..872b1cf 100644 (file)
@@ -2,19 +2,18 @@ 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
@@ -48,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'});