aboutsummaryrefslogtreecommitdiff
path: root/test/functional/ui/screen.lua
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2017-06-21 23:56:00 +0200
committerGitHub <noreply@github.com>2017-06-21 23:56:00 +0200
commit144f584948a0183382411dd583df9b18cd95b473 (patch)
tree0ea38fa17b41f5e2871cf0259944f67310f6479d /test/functional/ui/screen.lua
parentcb8e47c4f88f12e2a107698a250410561807395a (diff)
parent476c28f433ebd7e3c8dfc2d31c59b3fc4c1c02e5 (diff)
downloadrneovim-144f584948a0183382411dd583df9b18cd95b473.tar.gz
rneovim-144f584948a0183382411dd583df9b18cd95b473.tar.bz2
rneovim-144f584948a0183382411dd583df9b18cd95b473.zip
Merge #6914 from ZyX-I/func-def-trailing-error
Allow multiple function definitions in one :execute
Diffstat (limited to 'test/functional/ui/screen.lua')
-rw-r--r--test/functional/ui/screen.lua5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/functional/ui/screen.lua b/test/functional/ui/screen.lua
index 7d9cd6c026..5408e1e195 100644
--- a/test/functional/ui/screen.lua
+++ b/test/functional/ui/screen.lua
@@ -198,8 +198,9 @@ function Screen:expect(expected, attr_ids, attr_ignore, condition, any)
condition = expected
expected = nil
else
- -- Remove the last line and dedent.
- expected = dedent(expected:gsub('\n[ ]+$', ''))
+ -- Remove the last line and dedent. Note that gsub returns more then one
+ -- value.
+ expected = dedent(expected:gsub('\n[ ]+$', ''), 0)
for row in expected:gmatch('[^\n]+') do
row = row:sub(1, #row - 1) -- Last char must be the screen delimiter.
table.insert(expected_rows, row)