summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/run.scm10
-rw-r--r--tests/testlib.scm2
2 files changed, 9 insertions, 3 deletions
diff --git a/tests/run.scm b/tests/run.scm
index 7759b24..9ad7fd8 100644
--- a/tests/run.scm
+++ b/tests/run.scm
@@ -304,7 +304,10 @@
(test-group "alist form data body with custom port"
(let* ((string-port (open-input-string "the file's contents"))
- (custom-port (make-input-port (lambda () (read-char string-port)) (constantly #t) (lambda () (close-input-port string-port))))
+ (custom-port (make-input-port (lambda () (read-char string-port))
+ (constantly #t)
+ (lambda () (close-input-port string-port))
+ read-bytevector: (lambda (p bytes buf off) (read-bytevector! buf string-port off bytes))))
(log (with-server-response
(lambda ()
(with-input-from-request
@@ -350,7 +353,10 @@
(test-group "alist form data body with custom port using HTTP/1.0"
(let* ((string-port (open-input-string "the file's contents"))
- (custom-port (make-input-port (lambda () (read-char string-port)) (constantly #t) (lambda () (close-input-port string-port))))
+ (custom-port (make-input-port (lambda () (read-char string-port))
+ (constantly #t)
+ (lambda () (close-input-port string-port))
+ read-bytevector: (lambda (p bytes buf off) (read-bytevector! buf string-port off bytes))))
(uri (uri-reference "http://example.com"))
(req (make-request uri: uri method: 'POST
major: 1 minor: 0))
diff --git a/tests/testlib.scm b/tests/testlib.scm
index 92e69da..e50e5da 100644
--- a/tests/testlib.scm
+++ b/tests/testlib.scm
@@ -3,7 +3,7 @@
;; TODO: Test HTTPS somehow?
-(import test uri-common intarweb srfi-1 srfi-18 (chicken tcp)
+(import (scheme base) test uri-common intarweb srfi-1 srfi-18 (chicken tcp)
(chicken string) (chicken io) (chicken file) (chicken format))
;; From intarweb