From 54f2b431ee102b89738080b3eb8fdeb09d2b32d4 Mon Sep 17 00:00:00 2001 From: Tobias Brox Date: Mon, 17 Dec 2018 12:22:17 +0100 Subject: testing with non-ascii characters in location field, ref https://github.com/tobixen/calendar-cli/issues/45 --- tests/script_test.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/script_test.sh b/tests/script_test.sh index 33f8530..a32bc64 100755 --- a/tests/script_test.sh +++ b/tests/script_test.sh @@ -26,6 +26,7 @@ calendar_cli() { ## CLEANUP from earlier failed test runs for uid in $($calendar_cli calendar agenda --from-time=2010-10-10 --agenda-days=1 --event-template='{uid}') ; do calendar_cli calendar delete --event-uid=$uid ; done +calendar_cli todo --categories scripttest delete ## TESTING @@ -39,7 +40,7 @@ echo "## Attempting to add a past event at 2010-10-09 20:00:00, 2 hours duration calendar_cli calendar add '2010-10-09 20:00:00+2h' 'testing testing' uid=$(echo $output | perl -ne '/uid=(.*)$/ && print $1') echo "## Attempting to add a past event at 2010-10-10 20:00:00, CET (1 hour duration is default)" -calendar_cli calendar add '2010-10-10 20:00:00+01:00' 'testing testing' --set-description='this is a test calendar event' +calendar_cli calendar add '2010-10-10 20:00:00+01:00' 'testing testing' --set-description='this is a test calendar event' --set-location='Москва' uid2=$(echo $output | perl -ne '/uid=(.*)$/ && print $1') echo "## Attempting to add a past event at 2010-10-11 20:00:00, CET, 3h duration" calendar_cli calendar add '2010-10-11 20:00:00+01:00+3h' 'testing testing' @@ -47,8 +48,8 @@ uid3=$(echo $output | perl -ne '/uid=(.*)$/ && print $1') echo "## OK: Added the event, uid is $uid" echo "## Taking out the agenda for 2010-10-09 + four days" -calendar_cli calendar agenda --from-time=2010-10-09 --agenda-days=4 --event-template='{description}' -echo $output | { grep -q 'this is a test calendar event' && echo "## OK: found the event" ; } || echo "## FAIL: didn't find the event" +calendar_cli calendar agenda --from-time=2010-10-09 --agenda-days=4 --event-template='{description} {location}' +echo $output | { grep -q 'this is a test calendar event Москва' && echo "## OK: found the event" ; } || echo "## FAIL: didn't find the event" echo "## Taking out the agenda for 2010-10-10, with uid" calendar_cli calendar agenda --from-time=2010-10-10 --agenda-days=1 --event-template='{dtstart} {uid}' -- cgit v1.2.3