aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorChristopher Baines <mail@cbaines.net>2024-12-27 22:14:51 +0000
committerChristopher Baines <mail@cbaines.net>2024-12-27 22:14:51 +0000
commit4e791aff6814e38da8b431b8ddb8444a32e34fe6 (patch)
tree657a240402eb5e64863d868ae1ee8f0fd498f2de /tests
parente8ab6f23d8611c6ebb308007306a9ec5752cfbf0 (diff)
downloadknots-4e791aff6814e38da8b431b8ddb8444a32e34fe6.tar
knots-4e791aff6814e38da8b431b8ddb8444a32e34fe6.tar.gz
Fix a bug in fibers-batch-map (and related procedures)
And add more tests.
Diffstat (limited to 'tests')
-rw-r--r--tests/parallelism.scm17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/parallelism.scm b/tests/parallelism.scm
index 0901b3c..7d8dea7 100644
--- a/tests/parallelism.scm
+++ b/tests/parallelism.scm
@@ -24,6 +24,16 @@
100
(iota 34))))))
+;; Test fibers-map with an empty list
+(run-fibers-for-tests
+ (lambda ()
+ (fibers-map identity '())))
+
+;; Test fibers-map with an empty vector
+(run-fibers-for-tests
+ (lambda ()
+ (fibers-map identity #())))
+
;; Test fibers-map with vectors
(run-fibers-for-tests
(lambda ()
@@ -43,4 +53,11 @@
(* 2 i))
(iota 34))))
+;; Test fibers-map-with-progress with an empty list
+(run-fibers-for-tests
+ (lambda ()
+ (fibers-map-with-progress
+ identity
+ '(()))))
+
(display "parallelism test finished successfully\n")