davical/testing/tests/regression-suite/0000-Setup-PUT-collection-user3.test
Andrew Ruthven 7c47658bee Make the curl and SQL requests when we see them
This allows us to have more complex test files where an action is taken, then
we test something, then another action is taken, etc.

Changes to test files are required so that URL is defined after all the
required settings are set.

Changes to the result files are either whitespace changes due to above logic
changes, or printing out a SQL Result header before each result. I figured it
was useful.
2024-04-01 22:57:10 +13:00

78 lines
1.9 KiB
Plaintext

#
# PUT a calendar collection to user3 so we have some starting events
#
# There is no CalDAV defined behaviour for this.
#
TYPE=PUT
HEADER=User-Agent: RSCDS Testing/0.9.x
HEADER=Content-Type: text/calendar; charset=utf-8
AUTH=user3:user3
HEAD
BEGINDATA
BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//Apple Inc.//iCal 3.0//EN
CALSCALE:GREGORIAN
BEGIN:VTIMEZONE
TZID:Europe/Helsinki
BEGIN:DAYLIGHT
TZOFFSETFROM:+0200
TZOFFSETTO:+0300
DTSTART:19810329T030000
RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=-1SU
TZNAME:EEST
END:DAYLIGHT
BEGIN:STANDARD
TZOFFSETFROM:+0300
TZOFFSETTO:+0200
DTSTART:19961027T040000
RRULE:FREQ=YEARLY;BYMONTH=10;BYDAY=-1SU
TZNAME:EET
END:STANDARD
END:VTIMEZONE
BEGIN:VEVENT
SEQUENCE:3
TRANSP:OPAQUE
UID:55F6EC95-2D21-4FB9-9AE1-A6E020B44AEB
DTSTART;TZID=Europe/Helsinki:20081025T133000
DTSTAMP:20081024T200745Z
RRULE:FREQ=MONTHLY;INTERVAL=1;BYDAY=1TU,2WE,3TH,4FR;BYMONTH=3,6,9,10,12
SUMMARY:Irregular meeting for User 3
CREATED:20081024T200734Z
DTEND;TZID=Europe/Helsinki:20081025T143000
END:VEVENT
BEGIN:VEVENT
SEQUENCE:2
TRANSP:OPAQUE
UID:174F9C2A-1223-40C4-9E06-6E91F2EA9491
DTSTART;TZID=Europe/Helsinki:20081024T084500
DTSTAMP:20081025T112653Z
SUMMARY:Dentist\'s Council meeting
RRULE:FREQ=MONTHLY;INTERVAL=1;BYDAY=TU,FR
CREATED:20081025T112648Z
DTEND;TZID=Europe/Helsinki:20081024T113000
END:VEVENT
END:VCALENDAR
ENDDATA
URL=http://regression.host/caldav.php/user3/home/
QUERY
SELECT caldav_data.user_no, caldav_type, logged_user,
uid, dtstamp, dtstart at time zone olson_name as dtstart, dtend at time zone olson_name as dtend, due, summary, location,
description, priority, class, transp, rrule, url,
percent_complete, tz_id, status,
caldav_data AS "A1 CalDAV DATA"
FROM caldav_data JOIN calendar_item USING(dav_name) JOIN timezones ON (tz_id=tzid)
WHERE caldav_data.dav_name ~ '^/user3/home/'
ENDQUERY
QUERY
SELECT count(*)
FROM caldav_data JOIN calendar_item USING(dav_name)
WHERE caldav_data.dav_name ~ '^/user3/home/'
ENDQUERY