[Rt-commit] r8888 - rtfm/branches/2.1-TESTING/t

ruz at bestpractical.com ruz at bestpractical.com
Tue Sep 4 10:55:50 EDT 2007


Author: ruz
Date: Tue Sep  4 10:55:48 2007
New Revision: 8888

Modified:
   rtfm/branches/2.1-TESTING/t/URI__a.pm.t

Log:
* add plan
* add additional checks

Modified: rtfm/branches/2.1-TESTING/t/URI__a.pm.t
==============================================================================
--- rtfm/branches/2.1-TESTING/t/URI__a.pm.t	(original)
+++ rtfm/branches/2.1-TESTING/t/URI__a.pm.t	Tue Sep  4 10:55:48 2007
@@ -3,7 +3,7 @@
 use strict;
 use warnings;
 
-use Test::More 'no_plan';
+use Test::More tests => 8;
 BEGIN { require 't/utils.pl' }
 
 use_ok 'RT';
@@ -14,14 +14,17 @@
 my $uri = RT::URI::a->new($RT::SystemUser);
 ok(ref($uri), "URI object exists");
 
-my $class = RT::FM::Class->new($RT::SystemUser);
-$class->Create(Name => 'URItest - '.$$);
-my $article = RT::FM::Article->new($RT::SystemUser);
-my ($id,$msg) = $article->Create(Name => 'Testing URI parsing - '. $$,
-                 Summary => 'In which this should load',
-                 Class => $class->Id);
-
+my $class = RT::FM::Class->new( $RT::SystemUser );
+$class->Create( Name => 'URItest - '. $$ );
+ok $class->id, 'created a class';
+my $article = RT::FM::Article->new( $RT::SystemUser );
+my ($id, $msg) = $article->Create(
+    Name    => 'Testing URI parsing - '. $$,
+    Summary => 'In which this should load',
+    Class => $class->Id
+);
 ok($id,$msg);
+
 my $uristr = "a:" . $article->Id;
 $uri->ParseURI($uristr);
 is(ref($uri->Object), "RT::FM::Article", "Object loaded is an article");


More information about the Rt-commit mailing list