imip-agent

tests/test_resource_invitation_recurring.sh

1039:a12150034cbd
2016-02-08 Paul Boddie Added a journal storage area, maintaining quota and collective scheduling data for scheduling decisions. Introduced confirmation and retraction functions for resource scheduling so that quotas and collective schedules can be maintained and thus queried by scheduling functions. Updated the documentation, tools and tests.
     1 #!/bin/sh     2      3 . "`dirname \"$0\"`/common.sh"     4      5 USER="mailto:resource-room-confroom@example.com"     6      7 mkdir -p "$PREFS/$USER"     8 echo 'Europe/Oslo' > "$PREFS/$USER/TZID"     9 echo 'share' > "$PREFS/$USER/freebusy_sharing"    10     11   "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/fb-request-all.txt" 2>> $ERROR \    12 | "$SHOWMAIL" \    13 > out0.tmp    14     15    grep -q 'METHOD:REPLY' out0.tmp \    16 && ! grep -q '^FREEBUSY' out0.tmp \    17 && echo "Success" \    18 || echo "Failed"    19     20   "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/event-request-recurring.txt" 2>> $ERROR \    21 | "$SHOWMAIL" \    22 > out2.tmp    23     24    grep -q 'METHOD:REPLY' out2.tmp \    25 && grep -q 'ATTENDEE;PARTSTAT=ACCEPTED' out2.tmp \    26 && echo "Success" \    27 || echo "Failed"    28     29   "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/fb-request-all.txt" 2>> $ERROR \    30 | "$SHOWMAIL" \    31 > out3.tmp    32     33    grep -q 'METHOD:REPLY' out3.tmp \    34 && [ `grep 'FREEBUSY;FBTYPE=BUSY' out3.tmp | wc -l` = '3' ] \    35 && grep -q 'FREEBUSY;FBTYPE=BUSY:20141212T090000Z/20141212T100000Z' out3.tmp \    36 && echo "Success" \    37 || echo "Failed"    38     39   "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/event-cancel-recurring-instance.txt" 2>> $ERROR    40 echo "Cancel..."    41     42   "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/fb-request-all.txt" 2>> $ERROR \    43 | "$SHOWMAIL" \    44 > out4.tmp    45     46    grep -q 'METHOD:REPLY' out4.tmp \    47 && [ `grep 'FREEBUSY;FBTYPE=BUSY' out4.tmp | wc -l` = '2' ] \    48 && ! grep -q 'FREEBUSY;FBTYPE=BUSY:20141114T090000Z/20141114T100000Z' out4.tmp \    49 && echo "Success" \    50 || echo "Failed"    51     52   "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/event-request-recurring-reschedule-instance.txt" 2>> $ERROR \    53 | "$SHOWMAIL" \    54 > out5.tmp    55     56    grep -q 'METHOD:REPLY' out5.tmp \    57 && grep -q 'ATTENDEE;PARTSTAT=ACCEPTED' out5.tmp \    58 && echo "Success" \    59 || echo "Failed"    60     61   "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/fb-request-all.txt" 2>> $ERROR \    62 | "$SHOWMAIL" \    63 > out6.tmp    64     65    grep -q 'METHOD:REPLY' out6.tmp \    66 && grep -q 'FREEBUSY;FBTYPE=BUSY:20141011T080000Z/20141011T090000Z' out6.tmp \    67 && ! grep -q 'FREEBUSY;FBTYPE=BUSY:20141010T080000Z/20141010T090000Z' out6.tmp \    68 && echo "Success" \    69 || echo "Failed"    70     71   "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/event-cancel-recurring.txt" 2>> $ERROR    72 echo "Cancel..."    73     74   "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/fb-request-all.txt" 2>> $ERROR \    75 | "$SHOWMAIL" \    76 > out7.tmp    77     78    grep -q 'METHOD:REPLY' out7.tmp \    79 && ! grep -q '^FREEBUSY' out7.tmp \    80 && echo "Success" \    81 || echo "Failed"