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-day.txt" 2>> $ERROR \ 21 | "$SHOWMAIL" \ 22 > out1.tmp 23 24 grep -q 'METHOD:REPLY' out1.tmp \ 25 && grep -q 'ATTENDEE;PARTSTAT=ACCEPTED' out1.tmp \ 26 && echo "Success" \ 27 || echo "Failed" 28 29 "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/fb-request-all.txt" 2>> $ERROR \ 30 | "$SHOWMAIL" \ 31 > out2.tmp 32 33 grep -q 'METHOD:REPLY' out2.tmp \ 34 && [ `grep 'FREEBUSY;FBTYPE=BUSY' out2.tmp | wc -l` = '3' ] \ 35 && grep -q 'FREEBUSY;FBTYPE=BUSY:20141211T230000Z/20141212T230000Z' out2.tmp \ 36 && echo "Success" \ 37 || echo "Failed" 38 39 "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/event-request-recurring-day-reschedule-instance.txt" 2>> $ERROR \ 40 | "$SHOWMAIL" \ 41 > out3.tmp 42 43 grep -q 'METHOD:REPLY' out3.tmp \ 44 && grep -q 'ATTENDEE;PARTSTAT=ACCEPTED' out3.tmp \ 45 && echo "Success" \ 46 || echo "Failed" 47 48 "$RESOURCE_SCRIPT" $ARGS < "$TEMPLATES/fb-request-all.txt" 2>> $ERROR \ 49 | "$SHOWMAIL" \ 50 > out4.tmp 51 52 grep -q 'METHOD:REPLY' out4.tmp \ 53 && grep -q 'FREEBUSY;FBTYPE=BUSY:20141114T230000Z/20141115T230000Z' out4.tmp \ 54 && ! grep -q 'FREEBUSY;FBTYPE=BUSY:20141113T230000Z/20141114T230000Z' out4.tmp \ 55 && echo "Success" \ 56 || echo "Failed"