[svk-commit] r2930 - in trunk: t/bm
nobody at bestpractical.com
nobody at bestpractical.com
Mon Jun 23 04:14:31 EDT 2008
Author: clsung
Date: Mon Jun 23 04:14:30 2008
New Revision: 2930
Modified:
trunk/lib/SVK/Command/Branch.pm
trunk/t/bm/basic.t
Log:
- http://task.hm/FFC2
- with tests updated
- fix w/o tests
- http://task.hm/FFC4
- http://task.hm/FFC5
Modified: trunk/lib/SVK/Command/Branch.pm
==============================================================================
--- trunk/lib/SVK/Command/Branch.pm (original)
+++ trunk/lib/SVK/Command/Branch.pm Mon Jun 23 04:14:30 2008
@@ -68,6 +68,7 @@
'C|check-only' => 'check_only',
'P|patch=s' => 'patch',
'all' => 'all',
+ 'export' => 'export',
'from=s' => 'from',
'local' => 'local',
'project=s' => 'project',
@@ -224,7 +225,7 @@
$logger->info (sprintf $fmt, $_, ' (in local)') for @{$branches};
} else {
- my $branches = $proj->branches ($self->{local});
+ my $branches = $self->{tag} ? $proj->tags() : $proj->branches ($self->{local});
my $fmt = "%s\n"; # here to change layout
$logger->info (sprintf $fmt, $_) for @{$branches};
@@ -581,7 +582,7 @@
return ;
}
- my $newtarget_path = $proj->branch_path($branch_name, $self->{local});
+ my $newtarget_path = $self->dst_path($proj, $branch_name);
unshift @arg, $newtarget_path, $checkout_path;
return $self->SUPER::parse_arg(@arg);
}
Modified: trunk/t/bm/basic.t
==============================================================================
--- trunk/t/bm/basic.t (original)
+++ trunk/t/bm/basic.t Mon Jun 23 04:14:30 2008
@@ -1,7 +1,7 @@
#!/usr/bin/perl -w
use strict;
use SVK::Test;
-plan tests => 13;
+plan tests => 16;
our $output;
my ($xd, $svk) = build_test('test');
@@ -67,3 +67,11 @@
is_output($svk, 'br', ['-l', '--all', '//mirror/MyProject'],
['Foo', 'feature/foo', 'feature/foobar (in local)']);
+is_output_like ($svk, 'branch', ['--create', 'tagA', '--tag'],
+ qr'Project tag created: tagA');
+
+is_output($svk, 'br', ['-l', '--all', '//mirror/MyProject'],
+ ['Foo', 'feature/foo', 'tagA (tags)', 'feature/foobar (in local)']);
+
+is_output($svk, 'br', ['-l', '--tag', '//mirror/MyProject'],
+ ['tagA']);
More information about the svk-commit
mailing list