diff options
Diffstat (limited to 'nix/yants/tests/default.nix')
-rw-r--r-- | nix/yants/tests/default.nix | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/nix/yants/tests/default.nix b/nix/yants/tests/default.nix index da539ca3562b..8ad306df932b 100644 --- a/nix/yants/tests/default.nix +++ b/nix/yants/tests/default.nix @@ -92,4 +92,11 @@ deepSeq rec { (struct { a = int; b = option string; }) (sum { a = int; b = option string; }) ]; + + testRestrict = [ + ((restrict "< 42" (i: i < 42) int) 25) + ((restrict "not too long" (l: builtins.length l < 3) (list int)) [ 1 2 ]) + (list (restrict "eq 5" (v: v == 5) any) [ 5 5 5 ]) + ]; + } (pkgs.writeText "yants-tests" "All tests passed!") |