From 9044285f3388f829a0ddd13f8c3101b0844432fd Mon Sep 17 00:00:00 2001 From: Colin Kuskie Date: Fri, 21 Dec 2007 19:06:49 +0000 Subject: [PATCH] Commit the version tag, add skipAutoCommitWorkflow. Fix syntax errors. Set the plan. Half the tests are failing --- t/Asset/Wobject/GalleryAlbum/view.t | 25 ++++++++++++++++++------- 1 file changed, 18 insertions(+), 7 deletions(-) diff --git a/t/Asset/Wobject/GalleryAlbum/view.t b/t/Asset/Wobject/GalleryAlbum/view.t index b12a5f56e..03f933168 100644 --- a/t/Asset/Wobject/GalleryAlbum/view.t +++ b/t/Asset/Wobject/GalleryAlbum/view.t @@ -42,6 +42,11 @@ my $album = $gallery->addChild({ className => "WebGUI::Asset::Wobject::GalleryAlbum", ownerUserId => "3", # Admin + }, + undef, + undef, + { + skipAutoCommitWorkflows => 1, }); my @photos; for my $i ( 0 .. 5 ) { @@ -49,18 +54,19 @@ for my $i ( 0 .. 5 ) { = $album->addChild({ className => "WebGUI::Asset::File::Image::Photo", filename => "$i.jpg", + }, + undef, + undef, + { + skipAutoCommitWorkflows => 1, }); } -#---------------------------------------------------------------------------- -# Cleanup -END { - $versionTag->rollback(); -} +$versionTag->commit; #---------------------------------------------------------------------------- # Tests -plan no_plan => 1; +plan tests => 7; #---------------------------------------------------------------------------- # Test getFileIds and getFilePaginator @@ -117,7 +123,7 @@ $expected = { "file_loop" => bag( map { $_->getTemplateVars } @photos ), }; cmp_deeply( - $album->appendTemplateVarsFileLoop({},$self->getFilePaginator->getPageData), + $album->appendTemplateVarsFileLoop({},$album->getFilePaginator->getPageData), $expected ); @@ -130,3 +136,8 @@ $maker->prepare({ }); $maker->run; +#---------------------------------------------------------------------------- +# Cleanup +END { + $versionTag->rollback(); +}