Bug #745
- Fixed Bug #745, which allows projects names with spaces, provided the values are quoted (thanks to Duane Waddle). - Added unit test.
This commit is contained in:
@@ -28,7 +28,7 @@
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
use Test::More tests => 13;
|
||||
use Test::More tests => 14;
|
||||
|
||||
# Create the rc file.
|
||||
if (open my $fh, '>', 'pro.rc')
|
||||
@@ -62,6 +62,10 @@ $output = qx{../src/task rc:pro.rc 3 pro:bar};
|
||||
like ($output, qr/The project 'foo' has changed\. Project 'foo' is 50% complete \(1 of 2 tasks remaining\)\./, 'change project');
|
||||
like ($output, qr/The project 'bar' has changed\. Project 'bar' is 0% complete \(1 of 1 tasks remaining\)\./, 'change project');
|
||||
|
||||
# Test projects with spaces in them.
|
||||
$output = qx{../src/task rc:pro.rc 3 pro:"foo bar"};
|
||||
like ($output, qr/The project 'foo bar' has changed\./, 'project with spaces');
|
||||
|
||||
# Cleanup.
|
||||
unlink 'pending.data';
|
||||
ok (!-r 'pending.data', 'Removed pending.data');
|
||||
|
||||
Reference in New Issue
Block a user