Skip to content

Commit 7580dea

Browse files
authored
Prep jank support (jank-lang#71)
* prep jank support * prep * note block * wip * keyword * -Exception * -Exception * -Exception * update copied comment to match actual namespace * rm jank workaround
1 parent 1aac112 commit 7580dea

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+182
-179
lines changed

deps.edn

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{:paths ["test"]}

test/clojure/core_test/abs.cljc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
[-1/5 1/5]))
2323
(is (NaN? (abs ##NaN)))
2424
#?(:cljs (is (zero? (abs nil)))
25-
:default(is (thrown? Exception (abs nil)))))
25+
:default (is (thrown? #?(:clj Exception) (abs nil)))))
2626

2727
(testing "unboxed"
2828
(let [a 42

test/clojure/core_test/bit_and.cljc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55

66
(when-var-exists clojure.core/bit-and
77
(deftest test-bit-and
8-
#?(:clj (is (thrown? Exception (bit-and nil 1)))
9-
:cljs (is (= 0 (bit-and nil 1))))
10-
#?(:clj (is (thrown? Exception (bit-and 1 nil)))
11-
:cljs (is (= 0 (bit-and 1 nil))))
8+
#?(:cljs (is (= 0 (bit-and nil 1)))
9+
:default (is (thrown? #?(:clj Exception) (bit-and nil 1))))
10+
#?(:cljs (is (= 0 (bit-and 1 nil)))
11+
:default (is (thrown? #?(:clj Exception) (bit-and 1 nil))))
1212

1313
(are [ex a b] (= ex (bit-and a b))
1414
8 12 9

test/clojure/core_test/bit_and_not.cljc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55

66
(when-var-exists clojure.core/bit-and-not
77
(deftest test-bit-and-not
8-
#?(:clj (is (thrown? Exception (bit-and-not nil 1)))
9-
:cljs (is (= 0 (bit-and-not nil 1))))
10-
#?(:clj (is (thrown? Exception (bit-and-not 1 nil)))
11-
:cljs (is (= 1 (bit-and-not 1 nil))))
8+
#?(:cljs (is (= 0 (bit-and-not nil 1)))
9+
:default (is (thrown? #?(:clj Exception) (bit-and-not nil 1))))
10+
#?(:cljs (is (= 1 (bit-and-not 1 nil)))
11+
:default (is (thrown? #?(:clj Exception) (bit-and-not 1 nil))))
1212

1313
(are [ex a b] (= ex (bit-and-not a b))
1414
0 0 0

test/clojure/core_test/bit_clear.cljc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44

55
(when-var-exists clojure.core/bit-clear
66
(deftest test-bit-clear
7-
#?(:clj (is (thrown? Exception (bit-clear nil 1)))
8-
:cljs (is (= 0 (bit-clear nil 1))))
9-
#?(:clj (is (thrown? Exception (bit-clear 1 nil)))
10-
:cljs (is (= 0 (bit-clear 1 nil))))
7+
#?(:cljs (is (= 0 (bit-clear nil 1)))
8+
:default (is (thrown? #?(:clj Exception) (bit-clear nil 1))))
9+
#?(:cljs (is (= 0 (bit-clear 1 nil)))
10+
:default (is (thrown? #?(:clj Exception) (bit-clear 1 nil))))
1111

1212
(are [ex a b] (= ex (bit-clear a b))
1313
3 11 3)))

test/clojure/core_test/bit_flip.cljc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44

55
(when-var-exists clojure.core/bit-flip
66
(deftest test-bit-flip
7-
#?(:clj (is (thrown? Exception (bit-flip nil 1)))
8-
:cljs (is (= 2 (bit-flip nil 1))))
9-
#?(:clj (is (thrown? Exception (bit-flip 1 nil)))
10-
:cljs (is (= 0 (bit-flip 1 nil))))
7+
#?(:cljs (is (= 2 (bit-flip nil 1)))
8+
:default (is (thrown? #?(:clj Exception) (bit-flip nil 1))))
9+
#?(:cljs (is (= 0 (bit-flip 1 nil)))
10+
:default (is (thrown? #?(:clj Exception) (bit-flip 1 nil))))
1111

1212
(are [ex a b] (= ex (bit-flip a b))
1313
2r1111 2r1011 2

test/clojure/core_test/bit_not.cljc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44

55
(when-var-exists clojure.core/bit-not
66
(deftest test-bit-not
7-
#?(:clj (is (thrown? Exception (bit-not nil)))
8-
:cljs (is (= -1 (bit-not nil))))
7+
#?(:cljs (is (= -1 (bit-not nil)))
8+
:default (is (thrown? #?(:clj Exception) (bit-not nil))))
99

1010
(are [ex a] (= ex (bit-not a))
1111
-2r1000 2r0111

test/clojure/core_test/bit_or.cljc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55

66
(when-var-exists clojure.core/bit-or
77
(deftest test-bit-or
8-
#?(:clj (is (thrown? Exception (bit-or nil 1)))
9-
:cljs (is (bit-or nil 1)))
10-
#?(:clj (is (thrown? Exception (bit-or 1 nil)))
11-
:cljs (is (bit-or 1 nil)))
8+
#?(:cljs (is (bit-or nil 1))
9+
:default (is (thrown? #?(:clj Exception) (bit-or nil 1))))
10+
#?(:cljs (is (bit-or 1 nil))
11+
:default (is (thrown? #?(:clj Exception) (bit-or 1 nil))))
1212

1313
(are [ex a b] (= ex (bit-or a b))
1414
2r1101 2r1100 2r1001

test/clojure/core_test/bit_set.cljc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44

55
(when-var-exists clojure.core/bit-set
66
(deftest test-bit-set
7-
#?(:clj (is (thrown? Exception (bit-set nil 1)))
8-
:cljs (is (bit-set nil 1)))
9-
#?(:clj (is (thrown? Exception (bit-set 1 nil)))
10-
:cljs (is (bit-set 1 nil)))
7+
#?(:cljs (is (bit-set nil 1))
8+
:default (is (thrown? #?(:clj Exception) (bit-set nil 1))))
9+
#?(:cljs (is (bit-set 1 nil))
10+
:default (is (thrown? #?(:clj Exception) (bit-set 1 nil))))
1111

1212
(are [ex a b] (= ex (bit-set a b))
1313
2r1111 2r1011 2

test/clojure/core_test/bit_shift_left.cljc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44

55
(when-var-exists clojure.core/bit-shift-left
66
(deftest test-bit-shift-left
7-
#?(:clj (is (thrown? Exception (bit-shift-left nil 1)))
8-
:cljs (is (= 0 (bit-shift-left nil 1))))
9-
#?(:clj (is (thrown? Exception (bit-shift-left 1 nil)))
10-
:cljs (is (= 1 (bit-shift-left 1 nil))))
7+
#?(:cljs (is (= 0 (bit-shift-left nil 1)))
8+
:default (is (thrown? #?(:clj Exception) (bit-shift-left nil 1))))
9+
#?(:cljs (is (= 1 (bit-shift-left 1 nil)))
10+
:default (is (thrown? #?(:clj Exception) (bit-shift-left 1 nil))))
1111

1212
(are [ex a b] (= ex (bit-shift-left a b))
1313
1024 1 10

0 commit comments

Comments
 (0)