Skip to content

Commit

Permalink
tests: add messages to make things easier
Browse files Browse the repository at this point in the history
  • Loading branch information
gregsh committed Nov 16, 2020
1 parent a4160e9 commit 822fe7e
Showing 1 changed file with 22 additions and 22 deletions.
44 changes: 22 additions & 22 deletions testData/highlighting/ClojureFixes.clj
Original file line number Diff line number Diff line change
Expand Up @@ -5,34 +5,34 @@
(intersection #{1} #{1 2})
)
(do
(refer 'clojure.set :as <warning>s3</warning> :exclude '[intersection])
(refer 'clojure.set :as <warning descr="unable to resolve 's3'">s3</warning> :exclude '[intersection])
(union)
(<warning>intersection</warning> #{1} #{1 2})
(<warning>s3</warning>/union)
(<warning descr="unable to resolve 'intersection'">intersection</warning> #{1} #{1 2})
(<warning descr="unable to resolve 's3'">s3</warning>/union)
)
(do
(refer 'clojure.set :rename {union union_renamed})
(union_renamed)
(<warning>union</warning>)
(<warning descr="unable to resolve 'union'">union</warning>)
)

(do
(require 'clojure.set :as <warning>s1</warning>)
(<warning>union</warning>)
(<warning>s1</warning>/union)
(require 'clojure.set :as <warning descr="unable to resolve 's1'">s1</warning>)
(<warning descr="unable to resolve 'union'">union</warning>)
(<warning descr="unable to resolve 's1'">s1</warning>/union)
(require '[clojure.set :as s1])
(<warning>union</warning>)
(<warning descr="unable to resolve 'union'">union</warning>)
(s1/union)
)
(do
(require '[clojure [set :as s1] [data :as s2]])
(<warning>union</warning>)
(<warning descr="unable to resolve 'union'">union</warning>)
(s1/union)
)
(do
(require '(clojure zip [set :as s2]))
(<warning>union</warning>)
(<warning>s1</warning>/union)
(<warning descr="unable to resolve 'union'">union</warning>)
(<warning descr="unable to resolve 's1'">s1</warning>/union)
(s2/union)
)
(do
Expand All @@ -43,7 +43,7 @@
(do
(require '[clojure.string :refer [blank?]])
(blank?)
(<warning>trim-newline</warning>)
(<warning descr="unable to resolve 'trim-newline'">trim-newline</warning>)
(when-let [nsname 'foo.core']
(require (symbol nsname)))
)
Expand All @@ -64,11 +64,11 @@
(do
(use '(clojure zip [set :refer [union] :only [union]]))
(union)
(<warning>intersection</warning> #{1} #{1 2})
(<warning descr="unable to resolve 'intersection'">intersection</warning> #{1} #{1 2})
)

(do
(<warning>no-forward-def</warning>)
(<warning descr="unable to resolve 'no-forward-def'">no-forward-def</warning>)
(defn no-forward-def [] (no-forward-def))
(no-forward-def)
)
Expand All @@ -79,25 +79,25 @@
)
(do
(alias 'clojure.set-alias 'clojure.set)
(defn no-resolve-to-alias [] [<warning>clojure.set-alias</warning> clojure.set-alias/union])
(defn no-resolve-to-alias [] [<warning descr="unable to resolve 'clojure.set-alias'">clojure.set-alias</warning> clojure.set-alias/union])
)

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

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

::<warning>missing_alias</warning>/kwd
::<warning descr="unable to resolve 'missing_alias'">missing_alias</warning>/kwd

' ^meta #_ comment quoted_sym

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

(defrecord Record [x y])
Expand All @@ -106,7 +106,7 @@
)

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

(do
Expand Down Expand Up @@ -140,7 +140,7 @@
(-> (Object.) .getClass .getName))

(do
(alias <warning>bar</warning> <warning>clojure.set</warning>)
(alias <warning descr="unable to resolve 'bar'">bar</warning> <warning descr="unable to resolve 'clojure.set'">clojure.set</warning>)
(alias 'buz 'clojure.set)
(alias 'bar.buz 'clojure.core)
(buz/union))

0 comments on commit 822fe7e

Please sign in to comment.