mirror of
https://github.com/neovim/neovim.git
synced 2025-09-06 19:38:20 +00:00

https://github.com/mpeterv/luacheck/pull/81#issuecomment-261099606 > If you really want to use bleeding-edge version you should get the > rockspec from master branch, not a fixed commit ... > The correct way to install from a specific commit is cloning that > commit and running "luarocks make" from project directory. The reason > is that running "install" or "build" on an scm rockspec fetches > sources from master but uses build description from the rockspec > itself, which may be outdated.
47 lines
1.2 KiB
Lua
47 lines
1.2 KiB
Lua
local helpers = require('test.functional.helpers')(after_each)
|
|
local plugin_helpers = require('test.functional.plugin.helpers')
|
|
local Screen = require('test.functional.ui.screen')
|
|
|
|
local execute = helpers.execute
|
|
local meths = helpers.meths
|
|
local feed = helpers.feed
|
|
local eq = helpers.eq
|
|
|
|
local reset = plugin_helpers.reset
|
|
|
|
describe('matchparen', function()
|
|
local screen
|
|
|
|
before_each(function()
|
|
reset()
|
|
screen = Screen.new(20,5)
|
|
screen:attach()
|
|
screen:set_default_attr_ids( {
|
|
[0] = {bold=true, foreground=255},
|
|
[1] = {bold=true},
|
|
} )
|
|
end)
|
|
|
|
it('uses correct column after i_<Up>. Vim patch 7.4.1296', function()
|
|
execute('set noautoindent nosmartindent nocindent laststatus=0')
|
|
eq(1, meths.get_var('loaded_matchparen'))
|
|
feed('ivoid f_test()<cr>')
|
|
feed('{<cr>')
|
|
feed('}')
|
|
|
|
-- critical part: up + cr should result in an empty line inbetween the
|
|
-- brackets... if the bug is there, the empty line will be before the '{'
|
|
feed('<up>')
|
|
feed('<cr>')
|
|
|
|
screen:expect([[
|
|
void f_test() |
|
|
{ |
|
|
^ |
|
|
} |
|
|
{1:-- INSERT --} |
|
|
]])
|
|
|
|
end)
|
|
end)
|