Fix deduplicate for non-printable (and non-ASCII) characters.

This commit is contained in:
Ingo Karkat
2012-01-13 22:44:35 +01:00
parent 534184e4dd
commit 1160ae1276
2 changed files with 25 additions and 6 deletions

View File

@@ -6,7 +6,7 @@ Ensure we can deduplicate items successfully.
'
. ./test-lib.sh
cat >> todo.txt<<EOF
cat > todo.txt <<EOF
duplicated
two
x done
@@ -35,4 +35,24 @@ test_todo_session 'deduplicate without duplicates' <<EOF
TODO: No duplicate tasks found
EOF
cat > todo.txt <<EOF
normal task
a bold action
something else
a bold action
something more
EOF
test_todo_session 'deduplicate with non-printable duplicates' <<EOF
>>> todo.sh deduplicate
TODO: 1 duplicate task(s) removed
>>> todo.sh -p ls
2 a bold action
1 normal task
3 something else
4 something more
--
TODO: 4 of 4 tasks shown
EOF
test_done