Skip to content

Commit 822fe7e

Browse files
committed
tests: add messages to make things easier
1 parent a4160e9 commit 822fe7e

File tree

1 file changed

+22
-22
lines changed

1 file changed

+22
-22
lines changed

testData/highlighting/ClojureFixes.clj

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -5,34 +5,34 @@
55
(intersection #{1} #{1 2})
66
)
77
(do
8-
(refer 'clojure.set :as <warning>s3</warning> :exclude '[intersection])
8+
(refer 'clojure.set :as <warning descr="unable to resolve 's3'">s3</warning> :exclude '[intersection])
99
(union)
10-
(<warning>intersection</warning> #{1} #{1 2})
11-
(<warning>s3</warning>/union)
10+
(<warning descr="unable to resolve 'intersection'">intersection</warning> #{1} #{1 2})
11+
(<warning descr="unable to resolve 's3'">s3</warning>/union)
1212
)
1313
(do
1414
(refer 'clojure.set :rename {union union_renamed})
1515
(union_renamed)
16-
(<warning>union</warning>)
16+
(<warning descr="unable to resolve 'union'">union</warning>)
1717
)
1818

1919
(do
20-
(require 'clojure.set :as <warning>s1</warning>)
21-
(<warning>union</warning>)
22-
(<warning>s1</warning>/union)
20+
(require 'clojure.set :as <warning descr="unable to resolve 's1'">s1</warning>)
21+
(<warning descr="unable to resolve 'union'">union</warning>)
22+
(<warning descr="unable to resolve 's1'">s1</warning>/union)
2323
(require '[clojure.set :as s1])
24-
(<warning>union</warning>)
24+
(<warning descr="unable to resolve 'union'">union</warning>)
2525
(s1/union)
2626
)
2727
(do
2828
(require '[clojure [set :as s1] [data :as s2]])
29-
(<warning>union</warning>)
29+
(<warning descr="unable to resolve 'union'">union</warning>)
3030
(s1/union)
3131
)
3232
(do
3333
(require '(clojure zip [set :as s2]))
34-
(<warning>union</warning>)
35-
(<warning>s1</warning>/union)
34+
(<warning descr="unable to resolve 'union'">union</warning>)
35+
(<warning descr="unable to resolve 's1'">s1</warning>/union)
3636
(s2/union)
3737
)
3838
(do
@@ -43,7 +43,7 @@
4343
(do
4444
(require '[clojure.string :refer [blank?]])
4545
(blank?)
46-
(<warning>trim-newline</warning>)
46+
(<warning descr="unable to resolve 'trim-newline'">trim-newline</warning>)
4747
(when-let [nsname 'foo.core']
4848
(require (symbol nsname)))
4949
)
@@ -64,11 +64,11 @@
6464
(do
6565
(use '(clojure zip [set :refer [union] :only [union]]))
6666
(union)
67-
(<warning>intersection</warning> #{1} #{1 2})
67+
(<warning descr="unable to resolve 'intersection'">intersection</warning> #{1} #{1 2})
6868
)
6969

7070
(do
71-
(<warning>no-forward-def</warning>)
71+
(<warning descr="unable to resolve 'no-forward-def'">no-forward-def</warning>)
7272
(defn no-forward-def [] (no-forward-def))
7373
(no-forward-def)
7474
)
@@ -79,25 +79,25 @@
7979
)
8080
(do
8181
(alias 'clojure.set-alias 'clojure.set)
82-
(defn no-resolve-to-alias [] [<warning>clojure.set-alias</warning> clojure.set-alias/union])
82+
(defn no-resolve-to-alias [] [<warning descr="unable to resolve 'clojure.set-alias'">clojure.set-alias</warning> clojure.set-alias/union])
8383
)
8484

85-
@<warning>not-to-resolve</warning>
86-
#:some-ns {:some-key <warning>not-to-resolve</warning>}
85+
@<warning descr="unable to resolve 'not-to-resolve'">not-to-resolve</warning>
86+
#:some-ns {:some-key <warning descr="unable to resolve 'not-to-resolve'">not-to-resolve</warning>}
8787
(#'clojure.uuid/default-uuid-reader)
88-
(clojure.uuid/<warning>default-uuid-reader</warning>)
88+
(clojure.uuid/<warning descr="unable to resolve 'default-uuid-reader'">default-uuid-reader</warning>)
8989

9090
(def #_comment named-zero 0)
9191
{#_0 #_1 :a #_'(xxx) 'a :b #_:comm 'b #_2 #_3}
9292
# #_comment dbg 10
9393

94-
::<warning>missing_alias</warning>/kwd
94+
::<warning descr="unable to resolve 'missing_alias'">missing_alias</warning>/kwd
9595

9696
' ^meta #_ comment quoted_sym
9797

9898
(do
9999
(deftype Type [x y])
100-
(.equals (->Type 1 2) (<warning>map->Type</warning> {:x 1 :y 2}))
100+
(.equals (->Type 1 2) (<warning descr="unable to resolve 'map->Type'">map->Type</warning> {:x 1 :y 2}))
101101
(.-x (->Type 1 2))
102102

103103
(defrecord Record [x y])
@@ -106,7 +106,7 @@
106106
)
107107

108108
(defn keys-destr [{:keys [clojure.core/abc missing_ns/edf ijk]
109-
:or {abc 1, edf 2, ijk 3, <warning>missing_key</warning> 4}}]
109+
:or {abc 1, edf 2, ijk 3, <warning descr="unable to resolve 'missing_key'">missing_key</warning> 4}}]
110110
(print abc edf ijk))
111111

112112
(do
@@ -140,7 +140,7 @@
140140
(-> (Object.) .getClass .getName))
141141

142142
(do
143-
(alias <warning>bar</warning> <warning>clojure.set</warning>)
143+
(alias <warning descr="unable to resolve 'bar'">bar</warning> <warning descr="unable to resolve 'clojure.set'">clojure.set</warning>)
144144
(alias 'buz 'clojure.set)
145145
(alias 'bar.buz 'clojure.core)
146146
(buz/union))

0 commit comments

Comments
 (0)