aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2023-10-24 19:03:39 +0200
committerHugo Hörnquist <hugo@lysator.liu.se>2023-10-24 19:03:39 +0200
commitcf042d923f3dd9a6caf767d3f43140efec01ee17 (patch)
tree7b1dc2b34fa06defbe55bbe21eb30ac7e49c67b4
parentMerge (web uri-query) into (web query). (diff)
downloadcalp-cf042d923f3dd9a6caf767d3f43140efec01ee17.tar.gz
calp-cf042d923f3dd9a6caf767d3f43140efec01ee17.tar.xz
Repair webdav-propfind tests.
-rw-r--r--tests/unit/webdav/webdav-propfind.scm14
1 files changed, 8 insertions, 6 deletions
diff --git a/tests/unit/webdav/webdav-propfind.scm b/tests/unit/webdav/webdav-propfind.scm
index b3cc861f..143fe1cd 100644
--- a/tests/unit/webdav/webdav-propfind.scm
+++ b/tests/unit/webdav/webdav-propfind.scm
@@ -1,6 +1,8 @@
(define-module (test webdav-propfind)
:use-module ((hnh util) :select (sort*))
:use-module ((calp namespaces) :select (webdav))
+ :use-module (hnh util type)
+ :use-module (hnh util lens)
:use-module (calp webdav property)
:use-module (calp webdav propfind)
:use-module (calp webdav resource virtual)
@@ -17,12 +19,12 @@
(define (sort-propstats propstats)
(map
- (lambda (propstat)
- (propstat (propstat-status-code propstat)
- (sort* (propstat-property propstat)
- string< (compose symbol->string xml-element-tagname car))
- (propstat-error propstat)
- (propstat-response-description propstat)))
+ (lambda (pr)
+ (typecheck pr propstat?)
+ (modify pr propstat-property
+ (lambda (it)
+ (sort* it
+ string< (compose symbol->string xml-element-tagname car)))))
(sort* propstats < propstat-status-code)))