From 2a3ba9b993575da807ecf0f99a5c77ab5076a003 Mon Sep 17 00:00:00 2001 From: Arun Isaac Date: Mon, 16 Oct 2023 13:12:54 +0100 Subject: tests: Allow literal ints as arguments. * tests/ccwl.scm ("allow literal as arguments"): Rename to "allow literal strings as arguments". (print-int): New variable. ("allow literal ints as arguments"): New test. --- tests/ccwl.scm | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/tests/ccwl.scm b/tests/ccwl.scm index e7a0cb7..2f3f88d 100644 --- a/tests/ccwl.scm +++ b/tests/ccwl.scm @@ -163,10 +163,21 @@ #:message message))) #f))) -(test-assert "allow literals as arguments" +(test-assert "allow literal strings as arguments" (workflow () (print #:message "Hello"))) +;; TODO: Define this in the lexical scope of the test that requires +;; it. +(define print-int + (command #:inputs (number #:type int) + #:run "echo" number + #:outputs (printed-number #:type stdout))) + +(test-assert "allow literal ints as arguments" + (workflow () + (print-int #:number 42))) + (test-assert "step supplied with an unknown key must raise a &ccwl-violation condition" (guard (exception (else (ccwl-violation? exception))) -- cgit v1.2.3