diff options
Diffstat (limited to 'users/sterni/nix/string/tests/default.nix')
-rw-r--r-- | users/sterni/nix/string/tests/default.nix | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/users/sterni/nix/string/tests/default.nix b/users/sterni/nix/string/tests/default.nix index 576952673471..2caecbfa7b3f 100644 --- a/users/sterni/nix/string/tests/default.nix +++ b/users/sterni/nix/string/tests/default.nix @@ -45,9 +45,21 @@ let null) ]; + dontEval = builtins.throw "this should not get evaluated"; + + testMatch = it "tests match" [ + (assertEq "basic match usage" 42 + (string.match "answer" { + "answer" = 42; + "banana" = dontEval; + "maleur" = dontEval; + })) + ]; + in runTestsuite "nix.string" [ testTakeDrop testIndexing testFinding + testMatch ] |