[Bps-public-commit] r12531 - in Prophet/branches/moose: .
sartak at bestpractical.com
sartak at bestpractical.com
Mon May 19 09:47:26 EDT 2008
Author: sartak
Date: Mon May 19 09:47:26 2008
New Revision: 12531
Modified:
Prophet/branches/moose/ (props changed)
Prophet/branches/moose/t/real-conflicting-merge.t
Log:
r56351 at onn: sartak | 2008-05-19 09:47:15 -0400
Avoid invoking bin/prophet in real-conflicting-merge.t
Modified: Prophet/branches/moose/t/real-conflicting-merge.t
==============================================================================
--- Prophet/branches/moose/t/real-conflicting-merge.t (original)
+++ Prophet/branches/moose/t/real-conflicting-merge.t Mon May 19 09:47:26 2008
@@ -7,8 +7,8 @@
use Prophet::Test tests => 19;
as_alice {
- run_ok( 'prophet', [qw(create --type Bug --status new --from alice )], "Created a record as alice" );
- run_output_matches( 'prophet', [qw(search --type Bug --regex .)], [qr/new/], " Found our record" );
+ like(run_command(qw(create --type Bug --status new --from alice)), qr/Created Bug/, "Created a record as alice");
+ like(run_command(qw(search --type Bug --regex .)), qr/new/, "Found our record");
};
diag('Bob syncs from alice');
@@ -17,18 +17,18 @@
as_bob {
- run_ok( 'prophet', [qw(create --type Dummy --ignore yes)], "Created a dummy record" );
-
- run_ok( 'prophet', [ 'merge', '--to', repo_uri_for('bob'), '--from', repo_uri_for('alice') ], "Sync ran ok!" );
+ like(run_command(qw(create --type Dummy --ignore yes)), qr/Created Dummy/);
+ like(run_command('merge', '--to', repo_uri_for('bob'), '--from', repo_uri_for('alice')), qr/Merge complete/, "Sync ran ok!");
# check our local replicas
- my ( $ret, $out, $err ) = run_script( 'prophet', [qw(search --type Bug --regex .)] );
- like( $out, qr/new/, "We have the one record from alice" );
+ my $out = run_command(qw(search --type Bug --regex .));
+ like($out, qr/new/, "We have the one record from alice" );
if ( $out =~ /^(.*?)\s./ ) {
$record_id = $1;
}
- run_ok( 'prophet', [ 'update', '--type', 'Bug', '--uuid', $record_id, '--status' => 'stalled' ] );
+ like(run_command( 'update', '--type', 'Bug', '--uuid', $record_id, '--status' => 'stalled'), qr/Bug .* updated/);
+
run_output_matches(
'prophet',
[ 'show', '--type', 'Bug', '--uuid', $record_id ],
@@ -40,7 +40,8 @@
};
as_alice {
- run_ok( 'prophet', [ 'update', '--type', 'Bug', '--uuid', $record_id, '--status' => 'open' ] );
+ like(run_command('update', '--type', 'Bug', '--uuid', $record_id, '--status' => 'open' ), qr/Bug .* updated/);
+
run_output_matches(
'prophet',
[ 'show', '--type', 'Bug', '--uuid', $record_id ],
More information about the Bps-public-commit
mailing list