From 2c5cfd138ace486e36960a018e39d1b9c52cabc1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=80=E8=90=8C=E5=B0=8F=E6=B1=90?= Date: Wed, 19 Dec 2018 14:57:38 +0800 Subject: =?UTF-8?q?hover=E7=9A=84result=E5=9C=A8=E5=A4=96=E9=9D=A2?= =?UTF-8?q?=E7=AE=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/test/hover/init.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'server/test') diff --git a/server/test/hover/init.lua b/server/test/hover/init.lua index a11dff45..8177713e 100644 --- a/server/test/hover/init.lua +++ b/server/test/hover/init.lua @@ -12,7 +12,8 @@ function TEST(script) local ast = parser:ast(new_script) local vm = matcher.vm(ast) assert(vm) - local result = matcher.hover(vm, pos) + local result, source = matcher.findResult(vm, pos) + local result = matcher.hover(vm, result, source) assert(result) expect = expect:gsub('^[\r\n]*(.-)[\r\n]*$', '%1'):gsub('\r\n', '\n') result = result:gsub('```lua[\r\n]*', ''):gsub('[\r\n]*```', ''):gsub('^[\r\n]*(.-)[\r\n]*$', '%1'):gsub('\r\n', '\n') -- cgit v1.2.3