about summary refs log tree commit diff
path: root/tests/lang/eval-okay-replacestrings.nix
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lang/eval-okay-replacestrings.nix')
-rw-r--r--tests/lang/eval-okay-replacestrings.nix8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/lang/eval-okay-replacestrings.nix b/tests/lang/eval-okay-replacestrings.nix
new file mode 100644
index 000000000000..6284a0e660ae
--- /dev/null
+++ b/tests/lang/eval-okay-replacestrings.nix
@@ -0,0 +1,8 @@
+with builtins;
+
+[ (replaceStrings ["o"] ["a"] "foobar")
+  (replaceStrings ["o"] [""] "foobar")
+  (replaceStrings ["oo"] ["u"] "foobar")
+  (replaceStrings ["oo" "a"] ["a" "oo"] "foobar")
+  (replaceStrings ["oo" "oo"] ["u" "i"] "foobar")
+]