Fix regex for maven test to be case-sensitive
This commit is contained in:
parent
530952f046
commit
2aaac9da66
@ -246,14 +246,16 @@
|
||||
:command-line "mvn exec:java"
|
||||
:working-dir project-dir)
|
||||
(when-let ((test-class (and (buffer-file-name)
|
||||
(string-match-p ".*\\(Test\\|IT\\).*\\.java$" (buffer-file-name))
|
||||
(let ((case-fold-search nil))
|
||||
(string-match-p ".*\\(Test\\|IT\\).*\\.java$" (buffer-file-name)))
|
||||
(fboundp 'dap-java-test-class)
|
||||
(dap-java-test-class))))
|
||||
(list :command-name "test this class"
|
||||
:command-line (format "mvn test -Dtest=%s" test-class)
|
||||
:working-dir project-dir))
|
||||
(when-let ((test-method (and (buffer-file-name)
|
||||
(string-match-p ".*\\(Test\\|IT\\).*\\.java$" (buffer-file-name))
|
||||
(let ((case-fold-search nil))
|
||||
(string-match-p ".*\\(Test\\|IT\\).*\\.java$" (buffer-file-name)))
|
||||
(fboundp 'dap-java-test-method-at-point)
|
||||
(dap-java-test-method-at-point t))))
|
||||
(list :command-name "test this method"
|
||||
|
Loading…
Reference in New Issue
Block a user