- Modified feedback when the number of pending tasks in a project changes
  (thanks to Peter De Poorter).
This commit is contained in:
Paul Beckingham 2010-10-27 22:22:36 -04:00
parent f8d8d2f6b5
commit 01bb76b3b6
3 changed files with 9 additions and 9 deletions

View file

@ -41,26 +41,26 @@ if (open my $fh, '>', 'pro.rc')
# Test the project status numbers.
my $output = qx{../task rc:pro.rc add one pro:foo};
like ($output, qr/The scope of project 'foo' has changed\. Project 'foo' is 0% complete \(1 of 1 tasks remaining\)\./, 'add one');
like ($output, qr/The project 'foo' has changed\. Project 'foo' is 0% complete \(1 of 1 tasks remaining\)\./, 'add one');
$output = qx{../task rc:pro.rc add two pro:'foo'};
like ($output, qr/The scope of project 'foo' has changed\. Project 'foo' is 0% complete \(2 of 2 tasks remaining\)\./, 'add two');
like ($output, qr/The project 'foo' has changed\. Project 'foo' is 0% complete \(2 of 2 tasks remaining\)\./, 'add two');
$output = qx{../task rc:pro.rc add three pro:'foo'};
like ($output, qr/The scope of project 'foo' has changed\. Project 'foo' is 0% complete \(3 of 3 tasks remaining\)\./, 'add three');
like ($output, qr/The project 'foo' has changed\. Project 'foo' is 0% complete \(3 of 3 tasks remaining\)\./, 'add three');
$output = qx{../task rc:pro.rc add four pro:'foo'};
like ($output, qr/The scope of project 'foo' has changed\. Project 'foo' is 0% complete \(4 of 4 tasks remaining\)\./, 'add four');
like ($output, qr/The project 'foo' has changed\. Project 'foo' is 0% complete \(4 of 4 tasks remaining\)\./, 'add four');
$output = qx{../task rc:pro.rc 1 done};
like ($output, qr/Project 'foo' is 25% complete \(3 of 4 tasks remaining\)\./, 'done one');
$output = qx{../task rc:pro.rc 2 delete};
like ($output, qr/The scope of project 'foo' has changed\. Project 'foo' is 33% complete \(2 of 3 tasks remaining\)\./, 'delete two');
like ($output, qr/The project 'foo' has changed\. Project 'foo' is 33% complete \(2 of 3 tasks remaining\)\./, 'delete two');
$output = qx{../task rc:pro.rc 3 pro:bar};
like ($output, qr/The scope of project 'foo' has changed\. Project 'foo' is 50% complete \(1 of 2 tasks remaining\)\./, 'change project');
like ($output, qr/The scope of project 'bar' has changed\. Project 'bar' is 0% complete \(1 of 1 tasks remaining\)\./, 'change project');
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');
# Cleanup.
unlink 'pending.data';