imip-agent

tests/test_outgoing_invitation.sh

1195:a00216dc5cc8
2016-06-05 Paul Boddie Added delegate method placeholders.
     1 #!/bin/sh     2      3 . "`dirname \"$0\"`/common.sh"     4      5 USER="mailto:paul.boddie@example.com"     6      7 mkdir -p "$PREFS/$USER"     8 echo 'Europe/Oslo' > "$PREFS/$USER/TZID"     9 echo 'share' > "$PREFS/$USER/freebusy_sharing"    10     11 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-request.txt" 2>> $ERROR    12     13    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \    14 |  tee out1.tmp \    15 |  grep -q "^20141126T150000Z${TAB}20141126T160000Z" \    16 && echo "Success" \    17 || echo "Failed"    18     19 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-cancel.txt" 2>> $ERROR    20 echo "Cancel..."    21     22    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \    23 >  out2.tmp    24     25    ! grep -q '^2' "out2.tmp" \    26 && echo "Success" \    27 || echo "Failed"    28     29 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-request-recurring.txt" 2>> $ERROR    30     31    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \    32 >  out3.tmp    33     34    [ `cat "out3.tmp" | wc -l` = '3' ] \    35 && grep -q "^20141212T090000Z${TAB}20141212T100000Z" "out3.tmp" \    36 && echo "Success" \    37 || echo "Failed"    38     39 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-cancel-recurring-instance.txt" 2>> $ERROR    40     41    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \    42 >  out4.tmp    43     44    [ `cat "out4.tmp" | wc -l` = '2' ] \    45 && ! grep -q "^20141114T090000Z${TAB}20141114T100000Z" "out4.tmp" \    46 && echo "Success" \    47 || echo "Failed"    48     49 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-request-recurring-reschedule-instance.txt" 2>> $ERROR    50     51    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \    52 >  out5.tmp    53     54    grep -q "^20141011T080000Z${TAB}20141011T090000Z" "out5.tmp" \    55 && ! grep -q "^20141010T090000Z${TAB}20141010T100000Z" "out5.tmp" \    56 && echo "Success" \    57 || echo "Failed"    58     59 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-cancel-recurring.txt" 2>> $ERROR    60     61    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \    62 >  out6.tmp    63     64    ! grep -q '^2' "out6.tmp" \    65 && echo "Success" \    66 || echo "Failed"    67     68 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-request-recurring-day.txt" 2>> $ERROR    69     70    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \    71 >  out7.tmp    72     73    [ `cat "out7.tmp" | wc -l` = '3' ] \    74 && grep -q "^20141211T230000Z${TAB}20141212T230000Z" "out7.tmp" \    75 && echo "Success" \    76 || echo "Failed"    77     78 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-cancel-recurring-day.txt" 2>> $ERROR    79     80    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \    81 >  out8.tmp    82     83    ! grep -q '^2' "out8.tmp" \    84 && echo "Success" \    85 || echo "Failed"    86     87 # Switch time zones.    88     89 echo 'Europe/Mariehamn' > "$PREFS/$USER/TZID"    90     91 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-request-recurring.txt" 2>> $ERROR    92     93    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \    94 >  out9.tmp    95     96    [ `cat "out9.tmp" | wc -l` = '3' ] \    97 && grep -q "^20141212T090000Z${TAB}20141212T100000Z" "out9.tmp" \    98 && echo "Success" \    99 || echo "Failed"   100    101 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-cancel-recurring.txt" 2>> $ERROR   102    103    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \   104 >  out10.tmp   105    106    ! grep -q '^2' "out10.tmp" \   107 && echo "Success" \   108 || echo "Failed"   109    110 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-request-recurring-day.txt" 2>> $ERROR   111    112    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \   113 >  out11.tmp   114    115    [ `cat "out11.tmp" | wc -l` = '3' ] \   116 && grep -q "^20141211T230000Z${TAB}20141212T230000Z" "out11.tmp" \   117 && echo "Success" \   118 || echo "Failed"   119    120 "$OUTGOING_SCRIPT" $ARGS < "$TEMPLATES/event-cancel-recurring-day.txt" 2>> $ERROR   121    122    "$LIST_SCRIPT" $LIST_ARGS "$USER" "freebusy" \   123 >  out12.tmp   124    125    ! grep -q '^2' "out12.tmp" \   126 && echo "Success" \   127 || echo "Failed"