зеркало из https://github.com/golang/tools.git
add func rank tests
This commit is contained in:
Родитель
93dd394cc1
Коммит
e6acb1f2d2
|
@ -34,7 +34,7 @@ func testLSP(t *testing.T, exporter packagestest.Exporter) {
|
||||||
|
|
||||||
// We hardcode the expected number of test cases to ensure that all tests
|
// We hardcode the expected number of test cases to ensure that all tests
|
||||||
// are being executed. If a test is added, this number must be changed.
|
// are being executed. If a test is added, this number must be changed.
|
||||||
const expectedCompletionsCount = 60
|
const expectedCompletionsCount = 63
|
||||||
const expectedDiagnosticsCount = 13
|
const expectedDiagnosticsCount = 13
|
||||||
const expectedFormatCount = 3
|
const expectedFormatCount = 3
|
||||||
const expectedDefinitionsCount = 16
|
const expectedDefinitionsCount = 16
|
||||||
|
|
|
@ -0,0 +1,12 @@
|
||||||
|
package func_rank
|
||||||
|
|
||||||
|
var stringAVar = "var" //@item(stringAVar, "stringAVar", "string", "var")
|
||||||
|
func stringBFunc() string { return "str" } //@item(stringBFunc, "stringBFunc()", "string", "func")
|
||||||
|
type stringer struct{} //@item(stringer, "stringer", "struct{...}", "struct")
|
||||||
|
|
||||||
|
func _() stringer //@complete("tr", stringer, stringAVar, stringBFunc)
|
||||||
|
|
||||||
|
func _(val stringer) {} //@complete("tr", stringer, stringAVar, stringBFunc)
|
||||||
|
|
||||||
|
func (stringer) _() {} //@complete("tr", stringer, stringAVar, stringBFunc)
|
||||||
|
|
Загрузка…
Ссылка в новой задаче