Skip to content

Commit 99913b2

Browse files
committed
Exclude quickfix stack locations from runner
1 parent 64e306d commit 99913b2

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

autoload/OmniSharp/actions/test.vim

+4-3
Original file line numberDiff line numberDiff line change
@@ -148,19 +148,20 @@ function! s:run.single.test(testName, bufferTests) abort
148148
endfunction
149149

150150
function! s:run.single.complete(summary) abort
151-
if len(a:summary.locations) > 1
151+
let locations = filter(copy(a:summary.locations), 'has_key(v:val, "bufnr")')
152+
if len(locations) > 1
152153
" A single test was run, but multiple test results were returned. This can
153154
" happen when using e.g. NUnit TestCaseSources which re-run the test using
154155
" different arguments.
155156
call s:run.multiple.complete([a:summary])
156157
return
157158
endif
158-
if a:summary.pass && len(a:summary.locations) == 0
159+
if a:summary.pass && len(locations) == 0
159160
echomsg 'No tests were run'
160161
" Do we ever reach here?
161162
" call OmniSharp#testrunner#StateSkipped(bufnr)
162163
endif
163-
let location = a:summary.locations[0]
164+
let location = locations[0]
164165
call OmniSharp#testrunner#StateComplete(location)
165166
if a:summary.pass
166167
if get(location, 'type', '') ==# 'W'

0 commit comments

Comments
 (0)