neovim

Neovim text editor
git clone https://git.dasho.dev/neovim.git
Log | Files | Refs | README

modeline_spec.lua (511B)


      1 local t = require('test.testutil')
      2 local n = require('test.functional.testnvim')()
      3 
      4 local assert_alive = n.assert_alive
      5 local clear, command, write_file = n.clear, n.command, t.write_file
      6 
      7 describe('modeline', function()
      8  local tempfile = t.tmpname()
      9  before_each(clear)
     10 
     11  after_each(function()
     12    os.remove(tempfile)
     13  end)
     14 
     15  it('does not crash with a large version number', function()
     16    write_file(tempfile, 'vim100000000000000000000000')
     17    command('e! ' .. tempfile)
     18 
     19    assert_alive()
     20  end)
     21 end)