repair a test

main
Matthew Butterick 6 years ago committed by Matthew Butterick
parent 519192194f
commit c936d551ae

@ -79,7 +79,7 @@
[(cons (? valid-tag?) rest)
(match rest
[(list (? txexpr-attrs? attrs) (? qexpr? elems) ...)
(define mheq (make-hash)) ; want mutable hash
(define mheq (make-hasheq)) ; want mutable hash
(for ([kv (in-list attrs)])
(match-define (list k v) kv)
;; coerce number strings to actual numbers
@ -91,9 +91,10 @@
[_ x])))
(module+ test
(check-equal?
(qexpr->quad `(q ((font "Charter") (fontsize "12")) (q "Foo bar") ,(make-quad "zzz") (q "Zim Zam")))
(q (hasheq 'font "Charter" 'fontsize 12) (q "Foo bar") (q "zzz") (q "Zim Zam"))))
(check-true
(quad=?
(qexpr->quad `(q ((font "charter") (fontsize "12")) (q "Foo bar") ,(make-quad "zzz") (q "Zim Zam")))
(q (hasheq 'font "charter" 'fontsize 12) (q "Foo bar") (q "zzz") (q "Zim Zam")))))
(define (qml->qexpr x)
(parameterize ([permissive-xexprs #t]

Loading…
Cancel
Save