summaryrefslogtreecommitdiffstats
path: root/test/recur-010.sh
blob: 5567a401b07d1766eac3023044532cd9550603e4 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#!/bin/sh
# Calcurse support of recurrence rules does not include the rule part WKST (weekstart),
# but calcurse configuration does allow a choice between Monday and Sunday.

. "${TEST_INIT:-./test-init.sh}"

if [ "$1" = 'actual' ]; then
  TMP=tmp
  mkdir "$TMP"
  cp "$DATA_DIR"/conf "$TMP"
  sed -n '/page 131/p' "$DATA_DIR"/rfc5545 > "$TMP"/apts
  "$CALCURSE" -D "$TMP" -Q --filter-type cal --startday=08/01/1997 --range=31
  sed 's/=monday/=sunday/' "$DATA_DIR"/conf > "$TMP"/conf
  "$CALCURSE" -D "$TMP" -Q --filter-type cal --startday=08/01/1997 --range=31
  rm -rf "$TMP"
elif [ "$1" = 'expected' ]; then
  cat <<EOD
08/05/97:
 - 09:00 -> 09:00
	page 131: An example where the days generated makes a difference because of weekstart (RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU)

08/10/97:
 - 09:00 -> 09:00
	page 131: An example where the days generated makes a difference because of weekstart (RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU)

08/19/97:
 - 09:00 -> 09:00
	page 131: An example where the days generated makes a difference because of weekstart (RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU)

08/24/97:
 - 09:00 -> 09:00
	page 131: An example where the days generated makes a difference because of weekstart (RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU)
08/05/97:
 - 09:00 -> 09:00
	page 131: An example where the days generated makes a difference because of weekstart (RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU)

08/17/97:
 - 09:00 -> 09:00
	page 131: An example where the days generated makes a difference because of weekstart (RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU)

08/19/97:
 - 09:00 -> 09:00
	page 131: An example where the days generated makes a difference because of weekstart (RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU)

08/31/97:
 - 09:00 -> 09:00
	page 131: An example where the days generated makes a difference because of weekstart (RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU)
EOD
else
  ./run-test "$0"
fi