Unit Tests

- Updated 'run' test script to use 'task' instead of the defunct 'args' program.
This commit is contained in:
Paul Beckingham 2014-08-23 17:13:42 -04:00
parent 7e04e307c3
commit 63808b8920

49
src/run
View file

@ -1,56 +1,57 @@
echo 'data.location=.' > x
# 2.0.0 command line tests: # 2.0.0 command line tests:
# Support dropped for multiple quoted terms. # Support dropped for multiple quoted terms.
#echo #echo
#echo ./args rc:x rc.debug:1 rc.hyphenate:off list pro:foo \"\(du\<123.due or due.aft:som\)\" and entry \'\>\'8/31/2011 +2w+1d /pattern/ #echo ./task rc:x rc.debug:1 rc.hyphenate:off list pro:foo \"\(du\<123.due or due.aft:som\)\" and entry \'\>\'8/31/2011 +2w+1d /pattern/
# ./args rc:x rc.debug:1 rc.hyphenate:off list pro:foo "(du<123.due or due.aft:som)" and entry '>'8/31/2011 +2w+1d /pattern/ # ./task rc:x rc.debug:1 rc.hyphenate:off list pro:foo "(du<123.due or due.aft:som)" and entry '>'8/31/2011 +2w+1d /pattern/
# Support dropped for multiple quoted terms. # Support dropped for multiple quoted terms.
#echo #echo
#echo ./args rc:x rc.debug:1 rc.hyphenate:off list \"pro:foo \(du\<123.due or due.aft:som\) and entry \>8/31/2011 +2w+1d /pattern/\" #echo ./task rc:x rc.debug:1 rc.hyphenate:off list \"pro:foo \(du\<123.due or due.aft:som\) and entry \>8/31/2011 +2w+1d /pattern/\"
#./args rc:x rc.debug:1 rc.hyphenate:off list "pro:foo (du<123.due or due.aft:som) and entry >8/31/2011 +2w+1d /pattern/" #./task rc:x rc.debug:1 rc.hyphenate:off list "pro:foo (du<123.due or due.aft:som) and entry >8/31/2011 +2w+1d /pattern/"
echo echo
echo ./args rc:x rc.debug:1 1-3,5 7 or +tag modify pri:H /from/to/g -tag echo ./task rc:x rc.debug:1 1-3,5 7 or +tag modify pri:H /from/to/g -tag
./args rc:x rc.debug:1 1-3,5 7 or +tag modify pri:H /from/to/g -tag ./task rc:x rc.debug:1 1-3,5 7 or +tag modify pri:H /from/to/g -tag
echo echo
echo ./args rc:x rc.debug:1 add pro:foo due:eom-2wk recur:monthly do the thing echo ./task rc:x rc.debug:1 add pro:foo due:eom-2wk recur:monthly do the thing
./args rc:x rc.debug:1 add pro:foo due:eom-2wk recur:monthly do the thing ./task rc:x rc.debug:1 add pro:foo due:eom-2wk recur:monthly do the thing
echo echo
echo ./args rc:x rc.debug:1 add pro:foo -- due:eom-2wk recur:monthly do the thing echo ./task rc:x rc.debug:1 add pro:foo -- due:eom-2wk recur:monthly do the thing
./args rc:x rc.debug:1 add pro:foo -- due:eom-2wk recur:monthly do the thing ./task rc:x rc.debug:1 add pro:foo -- due:eom-2wk recur:monthly do the thing
echo echo
echo ./args rc:x rc.debug:1 1234 done pri:H echo ./task rc:x rc.debug:1 1234 done pri:H
./args rc:x rc.debug:1 1234 done pri:H ./task rc:x rc.debug:1 1234 done pri:H
echo echo
echo ./args rc:x rc.debug:1 a.b\<c \(one or two\) modify \'quoted string\' \\'not quoted\\' due:eom+1wk+1d echo ./task rc:x rc.debug:1 a.b\<c \(one or two\) modify \'quoted string\' \\'not quoted\\' due:eom+1wk+1d
./args rc:x rc.debug:1 a.b\<c \(one or two\) modify 'quoted string' \'not quoted\' due:eom+1wk+1d ./task rc:x rc.debug:1 a.b\<c \(one or two\) modify 'quoted string' \'not quoted\' due:eom+1wk+1d
# 2.4.0 command line tests: # 2.4.0 command line tests:
echo echo
echo ./args rc:~/.taskrc 123-128,140 142 mod pro:\'P 1\' +home /from/to/g /from/to/ rc.name=value echo ./task rc:~/.taskrc 123-128,140 142 mod pro:\'P 1\' +home /from/to/g /from/to/ rc.name=value
./args rc:~/.taskrc 123-128,140 142 mod pro:'P 1' +home /from/to/g /from/to/ rc.name=value ./task rc:~/.taskrc 123-128,140 142 mod pro:'P 1' +home /from/to/g /from/to/ rc.name=value
echo echo
echo ./args rc:~/..taskrc rc.name=value add -- modify +tag /from/to/g name:value /long/path/to/file.txt echo ./task rc:~/..taskrc rc.name=value add -- modify +tag /from/to/g name:value /long/path/to/file.txt
./args rc:~/..taskrc rc.name=value add -- modify +tag /from/to/g name:value /long/path/to/file.txt ./task rc:~/..taskrc rc.name=value add -- modify +tag /from/to/g name:value /long/path/to/file.txt
echo echo
echo ./args /pattern/ or 8ad2e3db-914d-4832-b0e6-72fa04f6e331,3b6218f9-726a-44fc-aa63-889ff52be442 limit:10 due.before:eom nex echo ./task /pattern/ or 8ad2e3db-914d-4832-b0e6-72fa04f6e331,3b6218f9-726a-44fc-aa63-889ff52be442 limit:10 due.before:eom nex
./args /pattern/ or 8ad2e3db-914d-4832-b0e6-72fa04f6e331,3b6218f9-726a-44fc-aa63-889ff52be442 limit:10 due.before:eom nex ./task /pattern/ or 8ad2e3db-914d-4832-b0e6-72fa04f6e331,3b6218f9-726a-44fc-aa63-889ff52be442 limit:10 due.before:eom nex
echo echo
echo ./args add Buy milk due:\'eow - 2d\' scheduled:due-1d echo ./task add Buy milk due:\'eow - 2d\' scheduled:due-1d
./args add Buy milk due:'eow - 2d' scheduled:due-1d ./task add Buy milk due:'eow - 2d' scheduled:due-1d
echo echo
echo ./args add Buy milk due:eow-2d scheduled:due-1d echo ./task add Buy milk due:eow-2d scheduled:due-1d
./args add Buy milk due:eow-2d scheduled:due-1d ./task add Buy milk due:eow-2d scheduled:due-1d