mirror of
https://gitlab.com/davical-project/davical.git
synced 2026-05-26 02:44:29 +00:00
Results for the first couple of regression tests for LOCK handling.
This commit is contained in:
parent
df692d2535
commit
d6c16bf31e
@ -0,0 +1,27 @@
|
||||
HTTP/1.1 200 OK
|
||||
Date: Dow, 01 Jan 2000 00:00:00 GMT
|
||||
Lock-Token: <opaquelocktoken:d18fcef9-bafa-7004-6989-67e7cfdca934>
|
||||
Content-Length: 473
|
||||
Content-Type: text/xml; charset="utf-8"
|
||||
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<prop xmlns="DAV:">
|
||||
<lockdiscovery xmlns="DAV:">
|
||||
<activelock>
|
||||
<locktype>
|
||||
<write/>
|
||||
</locktype>
|
||||
<lockscope>
|
||||
<exclusive/>
|
||||
</lockscope>
|
||||
<depth>0</depth>
|
||||
<owner>
|
||||
<href>http://andrew.mcmillan.net.nz/node/5/</href>
|
||||
</owner>
|
||||
<timeout>Second-8640000</timeout>
|
||||
<locktoken>
|
||||
<href>opaquelocktoken:d18fcef9-bafa-7004-6989-67e7cfdca934</href>
|
||||
</locktoken>
|
||||
</activelock>
|
||||
</lockdiscovery>
|
||||
</prop>
|
||||
@ -6,6 +6,7 @@ URL=http://mycaldav/caldav.php/user1/home/i1278618276.ics
|
||||
HEADER=Depth: 0
|
||||
HEADER=Timeout: Infinite,Second-4100000000
|
||||
HEADER=Content-type: text/xml; charset="utf-8"
|
||||
HEAD
|
||||
|
||||
#
|
||||
# Include the data in-line
|
||||
|
||||
27
testing/tests/regression-suite/801-Spec-LOCK-1.result
Normal file
27
testing/tests/regression-suite/801-Spec-LOCK-1.result
Normal file
@ -0,0 +1,27 @@
|
||||
HTTP/1.1 200 OK
|
||||
Date: Dow, 01 Jan 2000 00:00:00 GMT
|
||||
Content-Length: 473
|
||||
Content-Type: text/xml; charset="utf-8"
|
||||
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<prop xmlns="DAV:">
|
||||
<lockdiscovery xmlns="DAV:">
|
||||
<activelock>
|
||||
<locktype>
|
||||
<write/>
|
||||
</locktype>
|
||||
<lockscope>
|
||||
<exclusive/>
|
||||
</lockscope>
|
||||
<depth>0</depth>
|
||||
<owner>
|
||||
<href>http://andrew.mcmillan.net.nz/node/5/</href>
|
||||
</owner>
|
||||
<timeout>Second-8640000</timeout>
|
||||
<locktoken>
|
||||
<href>opaquelocktoken:d18fcef9-bafa-7004-6989-67e7cfdca934</href>
|
||||
</locktoken>
|
||||
</activelock>
|
||||
</lockdiscovery>
|
||||
</prop>
|
||||
Refreshed (should be 1) --- 1
|
||||
29
testing/tests/regression-suite/801-Spec-LOCK-1.test
Normal file
29
testing/tests/regression-suite/801-Spec-LOCK-1.test
Normal file
@ -0,0 +1,29 @@
|
||||
#
|
||||
# Test specification compliance for LOCK request
|
||||
# - Refresh the lock
|
||||
# No data is needed for a refresh
|
||||
#
|
||||
TYPE=LOCK
|
||||
URL=http://mycaldav/caldav.php/user1/home/i1278618276.ics
|
||||
|
||||
# Save the original lock time for later use
|
||||
GETSQL=oldlocktime
|
||||
SELECT start FROM locks WHERE dav_name = '/user1/home/i1278618276.ics'
|
||||
ENDSQL
|
||||
|
||||
# Get the lock token from the earlier lock
|
||||
GETSQL=locktoken
|
||||
SELECT opaquelocktoken FROM locks WHERE dav_name = '/user1/home/i1278618276.ics'
|
||||
ENDSQL
|
||||
|
||||
HEADER=Depth: 0
|
||||
HEADER=Timeout: Infinite,Second-4100000000
|
||||
HEADER=Content-type: text/xml; charset="utf-8"
|
||||
HEADER=Lock-Token: <opaquelocktoken:##locktoken##>
|
||||
HEAD
|
||||
|
||||
#
|
||||
# Do a query after the request
|
||||
QUERY
|
||||
SELECT 'Refreshed (should be 1)', start != '##oldlocktime##'::timestamp AS refresh_success FROM locks WHERE dav_name = '/user1/home/i1278618276.ics'
|
||||
ENDQUERY
|
||||
Loading…
x
Reference in New Issue
Block a user