File tree Expand file tree Collapse file tree 2 files changed +15
-3
lines changed Expand file tree Collapse file tree 2 files changed +15
-3
lines changed Original file line number Diff line number Diff line change @@ -5,9 +5,9 @@ EASK ?= eask
55
66TEST-FILES := $(shell ls test/* .el)
77
8- .PHONY : clean checkdoc lint package install compile test
8+ .PHONY : clean checkdoc lint package install compile download-sonarlint test
99
10- ci : clean package install compile test
10+ ci : clean package install compile download-sonarlint test
1111
1212package :
1313 @echo " Packaging..."
@@ -21,6 +21,10 @@ compile:
2121 @echo " Compiling..."
2222 $(EASK ) compile
2323
24+ download-sonarlint :
25+ @echo " Downloading SonarLint..."
26+ $(EASK ) eval ' (progn (require (quote lsp-sonarlint)) (lsp-sonarlint-download))'
27+
2428test :
2529 @echo " Testing..."
2630 $(EASK ) test ert $(TEST-FILES )
Original file line number Diff line number Diff line change 2828(require 'lsp-mode )
2929(require 'lsp-sonarlint )
3030
31+ (ert-deftest lsp-sonarlint-plugin-downloaded ()
32+ " Check whether you have downloaded SonarLint.
33+
34+ This is a prerequisite for all the integration tests. If this
35+ test fails, you need to download the SonarLint plugin using
36+
37+ make download-sonarlint"
38+ (should (file-exists-p (concat lsp-sonarlint-download-dir " /extension/server/sonarlint-ls.jar" ))))
39+
3140(defun lsp-sonarlint--wait-for (predicate hook timeout )
3241 " Register PREDICATE to run on HOOK, and wait until it returns t.
3342If that does not occur before TIMEOUT, throw an error."
@@ -72,7 +81,6 @@ only works for specific textDocument/didOpen:languageId."
7281 (lsp-enable-snippet nil )
7382 received-warnings)
7483 (let ((buf (find-file-noselect file))
75- (lsp-sonarlint-plugin-autodownload t )
7684 (diagnostics-updated nil )
7785 (register-warning (lambda (&rest w ) (when (equal (car w) 'lsp-mode )
7886 (push (cadr w) received-warnings)))))
You can’t perform that action at this time.
0 commit comments