summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorunwox <me@unwox.com>2024-12-23 22:26:21 +0600
committerunwox <me@unwox.com>2024-12-23 22:26:21 +0600
commit768e3e38ea11becee0d6b2496b66d03953ee53a8 (patch)
tree7b9b768924691d026faa80936f53ab191aaf9345 /lib
parent0413dc0cc0b75bb016dce603d5402bc470440142 (diff)
also print overall count of items when testing pegs
Diffstat (limited to 'lib')
-rw-r--r--lib/utils.fnl5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/utils.fnl b/lib/utils.fnl
index 046f646..f0be29b 100644
--- a/lib/utils.fnl
+++ b/lib/utils.fnl
@@ -13,7 +13,10 @@
(local parser (require :parser.parser))
(with-open [f (io.open file "r")]
(local contents (f:read :*all))
- (print (fennel.view (parser.match-many contents peg))))
+ (local items (parser.match-many contents peg))
+ (when items
+ (print (.. "count: " (# items))))
+ (print (fennel.view items)))
(os.exit 1))
{: must : measure : test-peg}