Initial commit

This commit is contained in:
Christopher Baines 2024-11-19 18:43:43 +00:00
commit 2f39c58d6c
27 changed files with 2969 additions and 0 deletions

18
tests/resource-pool.scm Normal file
View file

@ -0,0 +1,18 @@
(use-modules (tests)
(fibers)
(unit-test)
(knots resource-pool))
(run-fibers-for-tests
(lambda ()
(let ((resource-pool (make-resource-pool
(lambda ()
2)
1)))
(assert-equal
(with-resource-from-pool resource-pool
res
res)
2))))
(display "resource-pool test finished successfully\n")