Unit Tests

- Reduced complexity in the test.
This commit is contained in:
Paul Beckingham 2012-02-26 14:37:01 -05:00
parent 5396c718ef
commit ceabcdd6c3

View file

@ -40,15 +40,11 @@ if (open my $fh, '>', 'bug.rc')
# Bug 819: When I run "task add foo\'s bar." the description of the new task is "foo 's bar .". # Bug 819: When I run "task add foo\'s bar." the description of the new task is "foo 's bar .".
qx{../src/task rc:bug.rc add foo\\'s bar.}; qx{../src/task rc:bug.rc add foo\\'s bar.};
qx{../src/task rc:bug.rc add foo \\(bar\\)};
qx{../src/task rc:bug.rc add \\'baz \\(qux\\)\\'};
my $output = qx{../src/task rc:bug.rc ls}; my $output = qx{../src/task rc:bug.rc ls};
like ($output, qr/foo's bar\./, "foo's bar. --> preserved"); like ($output, qr/foo's bar\./, "foo's bar. --> preserved");
qx{../src/task rc:bug.rc add foo \\(bar\\)};
$output = qx{../src/task rc:bug.rc ls};
like ($output, qr/foo \(bar\)/, "foo \(bar\) -- preserved"); like ($output, qr/foo \(bar\)/, "foo \(bar\) -- preserved");
qx{../src/task rc:bug.rc add \\'baz \\(qux\\)\\'};
$output = qx{../src/task rc:bug.rc ls};
like ($output, qr/baz \(qux\)/, "baz \(qux\) -- preserved"); like ($output, qr/baz \(qux\)/, "baz \(qux\) -- preserved");
# Cleanup. # Cleanup.