File tree Expand file tree Collapse file tree 3 files changed +16
-2
lines changed Expand file tree Collapse file tree 3 files changed +16
-2
lines changed Original file line number Diff line number Diff line change @@ -10021,7 +10021,7 @@ Maps become Objects. Arbitrary keys are encoded to by key->js."
10021
10021
(set! js-reserved
10022
10022
(reduce #(do (gobject/set %1 %2 true ) %1 )
10023
10023
#js {} js-reserved-arr)))
10024
- (gobject/containsKey js-reserved x))
10024
+ (.hasOwnProperty js-reserved x))
10025
10025
10026
10026
(defn- demunge-pattern []
10027
10027
(when-not DEMUNGE_PATTERN
Original file line number Diff line number Diff line change 2922
2922
(is (= 'cljs.core/first?
2923
2923
(demunge (munge 'cljs.core/first?)))))
2924
2924
2925
+ (deftest test-munge
2926
+ (is (= " a_b" (munge " a-b" )))
2927
+ (is (= " a_SLASH_b" (munge " a/b" )))
2928
+ (is (= " _DOT__DOT_" (munge " .." )))
2929
+ (is (= " abstract$" (munge " abstract" )))
2930
+ (is (= 'abc (munge 'abc)))
2931
+ (is (= " toString" (munge " toString" ))))
2932
+
2925
2933
(deftest test-uuid-compile-and-runtime-hash
2926
2934
(is (= (hash (.toString #uuid " 0d1f9029-40fc-4728-8bdd-9862172d4370" ))
2927
2935
(hash (.toString (UUID. " 0d1f9029-40fc-4728-8bdd-9862172d4370" nil ))))))
Original file line number Diff line number Diff line change 66
66
67
67
(deftest test-compile-str
68
68
(async done
69
- (let [l (latch 3 done)]
69
+ (let [l (latch 4 done)]
70
70
(cljs/compile-str st " (+ 1 1)"
71
71
(fn [{:keys [error value]}]
72
72
(is (nil? error))
83
83
(fn [{:keys [error value]}]
84
84
(is (nil? error))
85
85
(is (= " (cljs.core.truth_(cljs.core.first)?1:2)" value))
86
+ (inc! l)))
87
+ (cljs/compile-str st " (.toString \" a\" )" nil
88
+ {:context :expr }
89
+ (fn [{:keys [error value]}]
90
+ (is (nil? error))
91
+ (is (= " \" a\" .toString()" value))
86
92
(inc! l))))))
87
93
88
94
(deftest test-eval-str
You can’t perform that action at this time.
0 commit comments