mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-07-30 04:23:24 +02:00
Unit tests - rc.t
- Added tests for the new rc.name=value form, in addition to the existing rc.name:value form.
This commit is contained in:
parent
99641e7b0b
commit
1bb907f76d
1 changed files with 14 additions and 2 deletions
|
@ -29,9 +29,9 @@
|
|||
use strict;
|
||||
use warnings;
|
||||
use File::Path;
|
||||
use Test::More tests => 4;
|
||||
use Test::More tests => 8;
|
||||
|
||||
# Create the rc file.
|
||||
# Create the rc file, using rc.name:value.
|
||||
unlink 'foo.rc';
|
||||
rmtree 'foo', 0, 0;
|
||||
qx{echo 'y'|../task rc:foo.rc rc.data.location:foo};
|
||||
|
@ -45,5 +45,17 @@ ok (!-r 'foo', 'Removed foo');
|
|||
unlink 'foo.rc';
|
||||
ok (!-r 'foo.rc', 'Removed foo.rc');
|
||||
|
||||
# Do it all again, with rc.name=value.
|
||||
qx{echo 'y'|../task rc:foo.rc rc.data.location:foo};
|
||||
|
||||
ok (-r 'foo.rc', 'Created default rc file');
|
||||
ok (-d 'foo', 'Created default data directory');
|
||||
|
||||
rmtree 'foo', 0, 0;
|
||||
ok (!-r 'foo', 'Removed foo');
|
||||
|
||||
unlink 'foo.rc';
|
||||
ok (!-r 'foo.rc', 'Removed foo.rc');
|
||||
|
||||
exit 0;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue