aboutsummaryrefslogtreecommitdiff
path: root/test/helpers.lua
diff options
context:
space:
mode:
authorAshkan Kiani <ashkan.k.kiani@gmail.com>2019-11-24 02:29:23 -0800
committerAshkan Kiani <ashkan.k.kiani@gmail.com>2019-11-24 02:29:23 -0800
commitb78fdd7ce55ef4f02bff9358ed3a3b7b68618a37 (patch)
tree9d1b7811402d1000e6d9284db054a99b71bbe53d /test/helpers.lua
parentf7c20b94c7c79ce883fa4f561c5c92f59a06641a (diff)
parentd0d38fc36e0c1602186aa540417070fa6c1e2746 (diff)
downloadrneovim-b78fdd7ce55ef4f02bff9358ed3a3b7b68618a37.tar.gz
rneovim-b78fdd7ce55ef4f02bff9358ed3a3b7b68618a37.tar.bz2
rneovim-b78fdd7ce55ef4f02bff9358ed3a3b7b68618a37.zip
Merge branch 'master' into lsp-followup
Diffstat (limited to 'test/helpers.lua')
-rw-r--r--test/helpers.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/helpers.lua b/test/helpers.lua
index 3f29a28c0d..98f003f208 100644
--- a/test/helpers.lua
+++ b/test/helpers.lua
@@ -99,6 +99,9 @@ function module.pcall_err(fn, ...)
-- to this:
-- Error executing lua: .../foo.lua:186: Expected string, got number
errmsg = errmsg:gsub([[lua: [a-zA-Z]?:?[^:]-[/\]([^:/\]+):%d+: ]], 'lua: .../%1: ')
+ -- Compiled modules will not have a path and will just be a name like
+ -- shared.lua:186, so strip the number.
+ errmsg = errmsg:gsub([[lua: ([^:/\ ]+):%d+: ]], 'lua: .../%1: ')
-- ^ Windows drive-letter (C:)
return errmsg
end