From 97d4fb537a6ca5a2ffe4da18bd1cbde2d4084fd0 Mon Sep 17 00:00:00 2001 From: Arun Isaac Date: Sun, 28 Jul 2019 11:32:16 +0530 Subject: tests: Add read-while eof-object test. * tests/utils.scm ("read-while returns eof-object on end of file"): New test. --- tests/utils.scm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/utils.scm b/tests/utils.scm index f54cfdd..b787d9f 100644 --- a/tests/utils.scm +++ b/tests/utils.scm @@ -30,4 +30,9 @@ (call-with-port (open-bytevector-input-port (make-bytevector 0)) (cut read-bytes-till <> (make-bytevector 1))))) +(test-assert "read-while returns eof-object on end of file" + (eof-object? + (call-with-input-string "" + (cut read-while <> read identity)))) + (test-end "utils") -- cgit v1.2.3