[Bps-public-commit] r15692 - in sd/trunk: .

sartak at bestpractical.com sartak at bestpractical.com
Mon Sep 1 23:32:25 EDT 2008


Author: sartak
Date: Mon Sep  1 23:32:25 2008
New Revision: 15692

Modified:
   sd/trunk/   (props changed)
   sd/trunk/t/01-create.t
   sd/trunk/t/02-create-with-editor.t
   sd/trunk/t/03-update-ticket-with-editor.t
   sd/trunk/t/04-update-ticket-comment-with-editor.t
   sd/trunk/t/sd-attachments.t
   sd/trunk/t/sd-comments.t

Log:
 r70851 at onn:  sartak | 2008-09-01 23:32:09 -0400
 Update tests to expect original_replica


Modified: sd/trunk/t/01-create.t
==============================================================================
--- sd/trunk/t/01-create.t	(original)
+++ sd/trunk/t/01-create.t	Mon Sep  1 23:32:25 2008
@@ -16,8 +16,6 @@
     diag "export SD_REPO=".$ENV{'PROPHET_REPO'} ."\n";
 }
 
-my $replica_uuid = Prophet::CLI->new->handle->uuid;
-
 # create from sd and push
 my ($yatta_id, $yatta_uuid) = create_ticket_ok( '--summary', 'YATTA');
 
@@ -34,7 +32,7 @@
         'status: new',
         qr/^created: \d{4}-\d{2}-\d{2}.+$/,
         qr/^creator: /,
-        "original_replica: $replica_uuid",
+        "original_replica: " . replica_uuid,
     ]
 );
 

Modified: sd/trunk/t/02-create-with-editor.t
==============================================================================
--- sd/trunk/t/02-create-with-editor.t	(original)
+++ sd/trunk/t/02-create-with-editor.t	Mon Sep  1 23:32:25 2008
@@ -11,7 +11,7 @@
     App::SD::Test->set_editor('ticket-create-editor.pl');
 }
 
-my $replica_uuid = Prophet::CLI->new->handle->uuid;
+my $replica_uuid = replica_uuid;
 my ($ticket_id, $ticket_uuid, $comment_id, $comment_uuid) = App::SD::Test::create_ticket_with_editor_ok();
 
 run_output_matches( 'sd', [ 'ticket',
@@ -35,8 +35,8 @@
         "id: $comment_id ($comment_uuid)",
         'content: We can create a comment at the same time.',
         qr/^created: \d{4}-\d{2}-\d{2}.+$/,
-        qr/^creator: .+ at .+$/,
-        qr/^ticket: $ticket_uuid$/,
+        qr/^creator: /,
         "original_replica: $replica_uuid",
+        qr/^ticket: $ticket_uuid$/,
     ]
 );

Modified: sd/trunk/t/03-update-ticket-with-editor.t
==============================================================================
--- sd/trunk/t/03-update-ticket-with-editor.t	(original)
+++ sd/trunk/t/03-update-ticket-with-editor.t	Mon Sep  1 23:32:25 2008
@@ -11,6 +11,8 @@
     App::SD::Test->set_editor('ticket-update-editor.pl');
 }
 
+my $replica_uuid = replica_uuid;
+
 # create ticket
 my ($ticket_id, $ticket_uuid) = create_ticket_ok( '--summary', 'zomg!',
     '--owner', 'foo at bar.com');
@@ -23,7 +25,8 @@
         'status: new',
         'owner: foo at bar.com',
         qr/^created: \d{4}-\d{2}-\d{2}.+$/,
-        qr/^creator: .+ at .+$/,
+        qr/^creator: /,
+        "original_replica: $replica_uuid",
     ]
 );
 
@@ -37,7 +40,8 @@
         'summary: summary changed',
         'status: new',
         qr/^created: \d{4}-\d{2}-\d{2}.+$/,
-        qr/^creator: .+ at .+$/,
+        qr/^creator: /,
+        "original_replica: $replica_uuid",
     ]
 );
 
@@ -46,7 +50,8 @@
         "id: $comment_id ($comment_uuid)",
         'content: We can create a comment at the same time.',
         qr/^created: \d{4}-\d{2}-\d{2}.+$/,
-        qr/^creator: .+ at .+$/,
+        qr/^creator: /,
+        "original_replica: $replica_uuid",
         qr/^ticket: $ticket_uuid$/,
     ]
 );

Modified: sd/trunk/t/04-update-ticket-comment-with-editor.t
==============================================================================
--- sd/trunk/t/04-update-ticket-comment-with-editor.t	(original)
+++ sd/trunk/t/04-update-ticket-comment-with-editor.t	Mon Sep  1 23:32:25 2008
@@ -11,6 +11,8 @@
     App::SD::Test->set_editor('ticket-comment-update-editor.pl');
 }
 
+my $replica_uuid = replica_uuid;
+
 # create ticket
 my ($ticket_id, $ticket_uuid) = create_ticket_ok( '--summary', 'zomg!' );
 
@@ -26,7 +28,8 @@
         "id: $comment_id ($comment_uuid)",
         qr/a new comment/,
         qr/^created: \d{4}-\d{2}-\d{2}.+$/,
-        qr/^creator: .+ at .+$/,
+        qr/^creator: /,
+        "original_replica: $replica_uuid",
         "ticket: $ticket_uuid",
     ]
 );
@@ -41,7 +44,8 @@
         "id: $comment_id ($comment_uuid)",
         qr/huzzah!/,
         qr/^created: \d{4}-\d{2}-\d{2}.+$/,
-        qr/^creator: .+ at .+$/,
+        qr/^creator: /,
+        "original_replica: $replica_uuid",
         "ticket: $ticket_uuid",
     ]
 );

Modified: sd/trunk/t/sd-attachments.t
==============================================================================
--- sd/trunk/t/sd-attachments.t	(original)
+++ sd/trunk/t/sd-attachments.t	Mon Sep  1 23:32:25 2008
@@ -11,6 +11,8 @@
     $ENV{'PROPHET_REPO'} = $ENV{'SD_REPO'} = File::Temp::tempdir( CLEANUP => 0 ) . '/_svb';
     diag "export SD_REPO=".$ENV{'PROPHET_REPO'} ."\n";
 }
+
+my $replica_uuid = replica_uuid;
 # create from sd and push
 my ($yatta_id, $yatta_uuid) =  create_ticket_ok( '--summary', 'YATTA', '--status', 'new' );
 
@@ -33,8 +35,9 @@
         "content: stub",
         "content_type: text/plain",
         qr/created: \d{4}-\d{2}-\d{2}.+/,
-        qr/creator: .+ at .+$/,
+        qr/creator: /,
         qr/paper_order.doc/,
+        "original_replica: $replica_uuid",
         "ticket: $yatta_uuid",
     ],
     [],
@@ -58,8 +61,9 @@
         "content: stub",
         "content_type: text/plain",
         qr/created: \d{4}-\d{2}-\d{2}.+/,
-        qr/creator: .+ at .+$/,
+        qr/creator: /,
         qr/plague_recipe.doc/,
+        "original_replica: " . replica_uuid,
         "ticket: $yatta_uuid"
     ],
     [],

Modified: sd/trunk/t/sd-comments.t
==============================================================================
--- sd/trunk/t/sd-comments.t	(original)
+++ sd/trunk/t/sd-comments.t	Mon Sep  1 23:32:25 2008
@@ -13,6 +13,8 @@
     diag $ENV{'PROPHET_REPO'};
 }
 
+my $replica_uuid = replica_uuid;
+
 # create from sd and push
 
 my ( $yatta_luid, $yatta_uuid )
@@ -37,6 +39,7 @@
         qr/This is a test/,
         qr/created: /,
         qr/creator: /,
+        "original_replica: $replica_uuid",
         "ticket: $yatta_uuid"
     ],
     [],
@@ -59,6 +62,7 @@
         qr/I hate you/,
         qr/created: /i,
         qr/creator: /i,
+        "original_replica: $replica_uuid",
         "ticket: $yatta_uuid"
     ],
     [],



More information about the Bps-public-commit mailing list