aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/ccwl.scm26
1 files changed, 26 insertions, 0 deletions
diff --git a/tests/ccwl.scm b/tests/ccwl.scm
index d667b32..d99650e 100644
--- a/tests/ccwl.scm
+++ b/tests/ccwl.scm
@@ -85,4 +85,30 @@
(else (ccwl-violation? exception)))
(output #'(message #:type int string))))
+(test-assert "command, when passed positional arguments, must raise a &ccwl-violation condition"
+ (guard (exception
+ (else (ccwl-violation? exception)))
+ (macroexpand
+ '(command foo
+ #:inputs (message #:type string)
+ #:run "echo" message
+ #:outputs (stdout #:type stdout)))))
+
+(test-assert "command, when passed an unrecognized keyword, must raise a &ccwl-violation condition"
+ (guard (exception
+ (else (ccwl-violation? exception)))
+ (macroexpand
+ '(command #:foo (message #:type string)
+ #:run "echo" message
+ #:outputs (stdout #:type stdout)))))
+
+(test-assert "command, when passed multiple arguments to a unary keyword, must raise a &ccwl-violation condition"
+ (guard (exception
+ (else (ccwl-violation? exception)))
+ (macroexpand
+ '(command #:inputs (message #:type string)
+ #:run "echo" message
+ #:outputs (stdout #:type stdout)
+ #:stdin "foo" "bar"))))
+
(test-end "ccwl")