about summary refs log tree commit diff
path: root/tests
diff options
context:
space:
mode:
authorArun Isaac2025-11-29 02:41:31 +0000
committerArun Isaac2025-11-29 02:41:31 +0000
commit9b4f73f0239b5473ea944893402cf95f6bebbc4d (patch)
tree9dd808d84d070693f89c48c6427dd4dd6c629a6e /tests
parent7f174cbfb1c788a6f850dccdbd8aca116043208e (diff)
downloadravanan-9b4f73f0239b5473ea944893402cf95f6bebbc4d.tar.gz
ravanan-9b4f73f0239b5473ea944893402cf95f6bebbc4d.tar.lz
ravanan-9b4f73f0239b5473ea944893402cf95f6bebbc4d.zip
workflow: Identify optional inputs with a boolean #f default.
Diffstat (limited to 'tests')
-rw-r--r--tests/workflow.scm31
1 files changed, 31 insertions, 0 deletions
diff --git a/tests/workflow.scm b/tests/workflow.scm
new file mode 100644
index 0000000..06b2609
--- /dev/null
+++ b/tests/workflow.scm
@@ -0,0 +1,31 @@
+;;; ravanan --- High-reproducibility CWL runner powered by Guix
+;;; Copyright © 2025 Arun Isaac <arunisaac@systemreboot.net>
+;;;
+;;; This file is part of ravanan.
+;;;
+;;; ravanan is free software: you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation, either version 3 of the License, or
+;;; (at your option) any later version.
+;;;
+;;; ravanan is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+;;; General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with ravanan.  If not, see <https://www.gnu.org/licenses/>.
+
+(use-modules (srfi srfi-64))
+
+(define optional-input?
+  (@@ (ravanan workflow) optional-input?))
+
+(test-begin "workflow")
+
+(test-assert "Inputs that have a boolean #f default are also optional"
+  (optional-input? `(("id" . "foo")
+                     ("type" . "boolean")
+                     ("default" . #f))))
+
+(test-end "workflow")