Merge branch 'master' of github.com:DAViCal/davical into github
[davical.git] / testing / tests / regression-suite / 0946-ACL.test
blob147dc9e4ea94baee8a5ffe1c9a880a5dc8436a34
2 # ACL setting default privileges on a collection to nothing, and
3 #     specific privileges to include read-acl.
5 TYPE=ACL
6 URL=http://regression.host/caldav.php/user1/home/
7 HEADER=User-Agent: RFC3744 Spec Tests
8 HEADER=Content-Type: text/xml; charset="UTF-8"
9 HEAD
12 BEGINDATA
13 <?xml version="1.0" encoding="utf-8" ?>
14 <acl xmlns="DAV:" xmlns:CalDAV="urn:ietf:params:xml:ns:caldav">
15   <ace>
16     <principal>
17       <href>/caldav.php/user4/</href>
18     </principal>
19     <grant>
20       <privilege><read/></privilege>
21       <privilege><read-acl/></privilege>
22       <privilege><read-current-user-privilege-set/></privilege>
23       <privilege><CalDAV:read-free-busy/></privilege>
24     </grant>
25   </ace>
26   <ace>
27     <principal><authenticated/></principal>
28     <grant>
29       <privilege/>
30     </grant>
31   </ace>
32 </acl>
33 ENDDATA
35 QUERY
36 SELECT by_principal, by_collection, privileges, p_to.displayname, to_principal
37    FROM grants JOIN dav_principal p_to ON (to_principal=principal_id)
38           LEFT JOIN collection ON (by_collection=collection.collection_id)
39   WHERE collection.dav_name = '/user1/home/'
40 ENDQUERY