go/gopls/internal/regtest/misc
Rob Findley f09387104b internal/lsp/source: improve logic for finding full syntax in hover
When enriching identifier info with full syntax, it's cleaner to find
the enclosing decl. Use the full decl in hover if we were unable to find
a node in the original type-checked package.

Update the regtest to exercise hovering in a non-workspace package.

Updates golang/go#46158

Change-Id: Ic1772a38fb1758fb57a09da9483a8853cc5498f1
Reviewed-on: https://go-review.googlesource.com/c/tools/+/333690
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
gopls-CI: kokoro <noreply+kokoro@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
2021-07-26 20:35:51 +00:00
..
add_import_test.go internal/lsp: add list_known_packages and add_import commands 2021-05-23 03:57:00 +00:00
configuration_test.go internal/lsp: move gopls/internal/regtest -> internal/lsp/regtest 2021-04-23 16:19:37 +00:00
debugserver_test.go internal/lsp/debug: add a facility to track known bugs 2021-05-10 23:21:19 +00:00
definition_test.go internal/lsp/source: support typeDefinition for function/method's return values 2021-05-06 03:15:21 +00:00
embed_test.go internal/lsp: move gopls/internal/regtest -> internal/lsp/regtest 2021-04-23 16:19:37 +00:00
failures_test.go internal/lsp: move gopls/internal/regtest -> internal/lsp/regtest 2021-04-23 16:19:37 +00:00
fix_test.go internal/lsp: move gopls/internal/regtest -> internal/lsp/regtest 2021-04-23 16:19:37 +00:00
formatting_test.go internal/lsp: handle incorrect import with CRLF line endings 2021-07-22 17:23:26 +00:00
generate_test.go internal/lsp: add a setting to batch didChangeWatchedFile notifications 2021-07-08 19:55:54 +00:00
highlight_test.go internal/lsp: move gopls/internal/regtest -> internal/lsp/regtest 2021-04-23 16:19:37 +00:00
hover_test.go internal/lsp/source: improve logic for finding full syntax in hover 2021-07-26 20:35:51 +00:00
imports_test.go internal/lsp: move gopls/internal/regtest -> internal/lsp/regtest 2021-04-23 16:19:37 +00:00
link_test.go internal/lsp: move gopls/internal/regtest -> internal/lsp/regtest 2021-04-23 16:19:37 +00:00
misc_test.go internal/lsp: move gopls/internal/regtest -> internal/lsp/regtest 2021-04-23 16:19:37 +00:00
references_test.go internal/lsp: move gopls/internal/regtest -> internal/lsp/regtest 2021-04-23 16:19:37 +00:00
semantictokens_test.go internal/lsp: get file URI from beginFileRequest in SemanticTokens 2021-05-12 22:01:29 +00:00
shared_test.go internal/lsp/regtest: fix a panic TestResolveImportCycle 2021-07-09 17:21:04 +00:00
template_test.go internal/lsp: support template files 2021-05-05 01:45:45 +00:00
vendor_test.go internal/lsp: move gopls/internal/regtest -> internal/lsp/regtest 2021-04-23 16:19:37 +00:00