aboutsummaryrefslogtreecommitdiff
path: root/tests/unit/webdav/webdav-util.scm
blob: 64c916ece5ce2e21787891bea0b9088f76967b49 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
(define-module (test webdav-test)
  :use-module (srfi srfi-64)
  :use-module (srfi srfi-71)
  :use-module (srfi srfi-88)
  :use-module (web uri)
  :use-module (calp webdav util)
   )

(test-equal "Parse-dav-line"
  `(1 2 access-control ,(string->uri "http://example.com/uri"))
  (parse-dav-line "1, 2, access-control, <http://example.com/uri>"))

(test-equal "write-dav-line"
  "1, 2, access-control, <http://example.com/uri>"
  (call-with-output-string
    (lambda (port)
      (write-dav-line
       `(1 2 access-control ,(string->uri "http://example.com/uri"))
       port))))

'((calp webdav util))