[Rt-commit] r20010 - rtir/2.5/trunk/t

sunnavy at bestpractical.com sunnavy at bestpractical.com
Wed Jun 17 21:29:00 EDT 2009


Author: sunnavy
Date: Wed Jun 17 21:28:59 2009
New Revision: 20010

Modified:
   rtir/2.5/trunk/t/013-custom-field-ip.t

Log:
make 013-custom-field-ip.t pass

Modified: rtir/2.5/trunk/t/013-custom-field-ip.t
==============================================================================
--- rtir/2.5/trunk/t/013-custom-field-ip.t	(original)
+++ rtir/2.5/trunk/t/013-custom-field-ip.t	Wed Jun 17 21:28:59 2009
@@ -35,7 +35,6 @@
         is( $cfs->Count, 1, 'field applies to queue' );
     }
 }
-
 my $rtir_user = RT::CurrentUser->new( rtir_user() );
 
 diag "create a ticket via web and set IP" if $ENV{'TEST_VERBOSE'};
@@ -46,11 +45,11 @@
         diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
 
         my $val = '192.168.20.'. ++$i;
-        my $id = create_rtir_ticket_ok(
-            $agent, $queue,
+        my $id = $agent->create_rtir_ticket_ok(
+            $queue,
             {
                 Subject => "test ip",
-                ($queue eq 'Blocks'? (Incident => $incident_id): ()),
+                ( $queue eq 'Blocks' ? ( Incident => $incident_id ) : () ),
             },
             { IP => $val },
         );
@@ -74,8 +73,8 @@
         diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
 
         my $val = '192.168.20.'. ++$i;
-        my $id = create_rtir_ticket_ok(
-            $agent, $queue,
+        my $id = $agent->create_rtir_ticket_ok(
+            $queue,
             {
                 Subject => "test ip in message",
                 ($queue eq 'Blocks'? (Incident => $incident_id): ()),
@@ -102,8 +101,8 @@
         diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
 
         my $val = '172.16.'. ++$i .'/31'; # add two hosts
-        my $id = create_rtir_ticket_ok(
-            $agent, $queue,
+        my $id = $agent->create_rtir_ticket_ok(
+            $queue,
             {
                 Subject => "test ip",
                 ($queue eq 'Blocks'? (Incident => $incident_id): ()),
@@ -133,8 +132,8 @@
         diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
 
         my $val = '172.16.'. ++$i .'/31'; # add two hosts
-        my $id = create_rtir_ticket_ok(
-            $agent, $queue,
+        my $id = $agent->create_rtir_ticket_ok(
+            $queue,
             {
                 Subject => "test ip in message",
                 ($queue eq 'Blocks'? (Incident => $incident_id): ()),
@@ -163,8 +162,8 @@
     foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Blocks' ) {
         diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
 
-        my $id = create_rtir_ticket_ok(
-            $agent, $queue,
+        my $id = $agent->create_rtir_ticket_ok(
+            $queue,
             {
                 Subject => "test ip in message",
                 ($queue eq 'Blocks'? (Incident => $incident_id): ()),
@@ -552,19 +551,19 @@
 
 diag "merge ticket, IPs should be merged";
 {
-    my $incident_id = create_rtir_ticket_ok(
-        $agent, 'Incidents',
+    my $incident_id = $agent->create_rtir_ticket_ok(
+        'Incidents',
         { Subject => "test" },
     );
-    my $b1_id = create_block(
-        $agent, {
+    my $b1_id = $agent->create_block(
+        {
             Subject => "test ip",
             Incident => $incident_id,
         },
         { IP => '172.16.0.1' },
     );
-    my $b2_id = create_block(
-        $agent, {
+    my $b2_id = $agent->create_block(
+        {
             Subject => "test ip",
             Incident => $incident_id,
         },
@@ -592,19 +591,19 @@
 
 diag "merge ticket with the same IP";
 {
-    my $incident_id = create_rtir_ticket_ok(
-        $agent, 'Incidents',
+    my $incident_id = $agent->create_rtir_ticket_ok(
+        'Incidents',
         { Subject => "test" },
     );
-    my $b1_id = create_block(
-        $agent, {
+    my $b1_id = $agent->create_block(
+        {
             Subject => "test ip",
             Incident => $incident_id,
         },
         { IP => '172.16.0.1' },
     );
-    my $b2_id = create_block(
-        $agent, {
+    my $b2_id = $agent->create_block(
+        {
             Subject => "test ip",
             Incident => $incident_id,
         },


More information about the Rt-commit mailing list