Fix erroneously removing pipe chars from input

cleaninput() unintentionally deletes the '|' character from input.  This
commit fixes it and adds test for adding tasks with a bunch of symbols.
This commit is contained in:
Nick Wilson
2011-01-31 21:07:35 -08:00
parent f1d339a537
commit 8e4364f5e1
2 changed files with 11 additions and 7 deletions

View File

@@ -58,19 +58,23 @@ TODO: 3 added.
TODO: 2 of 3 tasks shown
EOF
test_todo_session 'add with &' <<EOF
>>> todo.sh add "dig the garden & water the flowers"
4 dig the garden & water the flowers
test_todo_session 'add with symbols' <<EOF
>>> todo.sh add "~@#$%^&*()-_=+[{]}|;:',<.>/?"
4 ~@#$%^&*()-_=+[{]}|;:',<.>/?
TODO: 4 added.
>>> todo.sh add '\`!\\"'
5 \`!\\"
TODO: 5 added.
>>> todo.sh list
4 dig the garden & water the flowers
1 notice the daisies
2 smell the roses
3 smell the uppercase Roses
5 \`!\\"
4 ~@#$%^&*()-_=+[{]}|;:',<.>/?
--
TODO: 4 of 4 tasks shown
TODO: 5 of 5 tasks shown
EOF
test_done