Bug Fix: Issue 6 append and replace unexpected behavior if there's an & in task (even in quotes)

Using the cleaninput function, to escape &'s on certain actions.
Currently the actions needing escaped &'s are append, prepend and replace.
Other actions including add need unescaped &'s.
This commit is contained in:
Paul Mansfield
2009-09-05 20:36:38 +01:00
parent 5e71728cda
commit ddaf9ade22
5 changed files with 79 additions and 1 deletions

View File

@@ -55,4 +55,18 @@ TODO: 'smell the uppercase Roses' added on line 3.
TODO: 2 of 3 tasks shown from $HOME/todo.txt
EOF
test_todo_session 'add with &' <<EOF
>>> todo.sh add "dig the garden & water the flowers"
TODO: 'dig the garden & water the flowers' added on line 4.
>>> todo.sh list
4 dig the garden & water the flowers
1 notice the daisies
2 smell the roses
3 smell the uppercase Roses
--
TODO: 4 of 4 tasks shown from $HOME/todo.txt
EOF
test_done