some evals so the tests finish
Matt S Trout [Mon, 10 Jul 2006 01:16:47 +0000 (01:16 +0000)]
t/76joins.t

index 1e39dfb..e828d6d 100644 (file)
@@ -308,14 +308,15 @@ $tree_like = $schema->resultset('TreeLike')->search_related('children',
     { 'children.id' => 2, 'children_2.id' => 3 },
     { prefetch => { children => 'children' } }
   )->first;
-is($tree_like->children->first->children->first->name, 'quux', 'Tree search_related with prefetch ok');
+is(eval { $tree_like->children->first->children->first->name }, 'quux',
+   'Tree search_related with prefetch ok');
 
-$tree_like = $schema->resultset('TreeLike')->search(
+$tree_like = eval { $schema->resultset('TreeLike')->search(
     { 'children.id' => 2, 'children_2.id' => 5 }, 
     { join => [qw/children children/] }
   )->search_related('children', { 'children_3.id' => 6 }, { prefetch => 'children' }
-  )->first->children->first;
-is($tree_like->name, 'fong', 'Tree with multiple has_many joins ok');
+  )->first->children->first; };
+is(eval { $tree_like->name }, 'fong', 'Tree with multiple has_many joins ok');
 
 # test that collapsed joins don't get a _2 appended to the alias