[Bast-commits] r4637 - DBIx-Class-Tree-NestedSet/t

rafl at dev.catalyst.perl.org rafl at dev.catalyst.perl.org
Fri Jul 25 01:44:32 BST 2008


Author: rafl
Date: 2008-07-25 01:44:32 +0100 (Fri, 25 Jul 2008)
New Revision: 4637

Modified:
   DBIx-Class-Tree-NestedSet/t/basic.t
Log:
Test that root nodes don't have a parent.

Modified: DBIx-Class-Tree-NestedSet/t/basic.t
===================================================================
--- DBIx-Class-Tree-NestedSet/t/basic.t	2008-07-25 00:44:26 UTC (rev 4636)
+++ DBIx-Class-Tree-NestedSet/t/basic.t	2008-07-25 00:44:32 UTC (rev 4637)
@@ -1,6 +1,6 @@
 use strict;
 use warnings;
-use Test::More tests => 22;
+use Test::More tests => 23;
 use DBICx::TestDatabase;
 
 use FindBin;
@@ -17,6 +17,7 @@
 my $root = $trees->create({ content => 'foo' });
 isa_ok($root, 'DBIx::Class::Row');
 
+is($root->parent, undef, 'root has no parent');
 is($root->root->id, $root->id, 'root field gets set automatically');
 is($root->children->count, 0, 'no children, initially');
 is($root->nodes->count, 1, 'nodes include self');




More information about the Bast-commits mailing list