small fix
David Kamholz [Thu, 6 Jul 2006 21:29:53 +0000 (21:29 +0000)]
t/76joins.t

index d5b19ec..b807f8f 100644 (file)
@@ -295,16 +295,13 @@ $schema->storage->debug(0);
 
 cmp_ok($queries, '==', 1, 'Only one query run');
 
-$schema->storage->debugcb(undef);
-$schema->storage->debug(1);
-
 $tree_like = $schema->resultset('TreeLike')->search({'me.id' => 1});
 $tree_like = $tree_like->search_related('children')->search_related('children')->search_related('children')->first;
 is($tree_like->name, 'quux', 'Tree search_related ok');
 
-$tree_like = $schema->resultset('TreeLike')->search({ 'me.id' => 2 });
+$tree_like = $schema->resultset('TreeLike')->search({ 'children.id' => 2 });
 $tree_like = $tree_like->search_related('children', undef, { prefetch => { children => 'children' } })->first;
-is($tree_like->children->first->name, 'quux', 'Tree search_related with prefetch ok');
+is($tree_like->children->first->name, 'baz', 'Tree search_related with prefetch ok');
 
 $tree_like = $schema->resultset('TreeLike')->search(
     { 'children.id' => 2, 'children_2.id' => 5 },