[Catalyst-commits] r10916 -
Catalyst-Controller-DBIC-API/1.003/trunk/t/rpc
lukes at dev.catalyst.perl.org
lukes at dev.catalyst.perl.org
Fri Jul 17 09:17:24 GMT 2009
Author: lukes
Date: 2009-07-17 09:17:23 +0000 (Fri, 17 Jul 2009)
New Revision: 10916
Modified:
Catalyst-Controller-DBIC-API/1.003/trunk/t/rpc/update.t
Log:
added tests for controller class which can handle any object type
Modified: Catalyst-Controller-DBIC-API/1.003/trunk/t/rpc/update.t
===================================================================
--- Catalyst-Controller-DBIC-API/1.003/trunk/t/rpc/update.t 2009-07-17 08:54:05 UTC (rev 10915)
+++ Catalyst-Controller-DBIC-API/1.003/trunk/t/rpc/update.t 2009-07-17 09:17:23 UTC (rev 10916)
@@ -10,7 +10,7 @@
use RestTest;
use DBICTest;
-use Test::More tests => 23;
+use Test::More tests => 25;
use Test::WWW::Mechanize::Catalyst 'RestTest';
use HTTP::Request::Common;
use JSON::Syck;
@@ -118,3 +118,14 @@
$track->discard_changes;
is($track->title, 'baa', 'Title changed');
}
+
+{
+ my $req = POST( $any_track_update_url, {
+ position => '14'
+ });
+ $mech->request($req, $content_type);
+ cmp_ok( $mech->status, '==', 200, 'Position update okay' );
+
+ $track->discard_changes;
+ is($track->get_column('position'), '14', 'Position changed');
+}
More information about the Catalyst-commits
mailing list