diff --git a/tests/native_tests/language.hy b/tests/native_tests/language.hy index ab71791..f4c0e1c 100644 --- a/tests/native_tests/language.hy +++ b/tests/native_tests/language.hy @@ -517,6 +517,12 @@ (assert (= (get {:foo "bar"} :foo) "bar")) (assert (= (get {:bar "quux"} (get {:foo :bar} :foo)) "quux"))) +(defn test-keyword-clash [] + "NATIVE: test that keywords do not clash with normal strings" + + (assert (= (get {:foo "bar" ":foo" "quux"} :foo) "bar")) + (assert (= (get {:foo "bar" ":foo" "quux"} ":foo") "quux"))) + (defn test-eval [] "NATIVE: test eval" (assert (= 2 (eval (quote (+ 1 1)))))