From 9d2985ecba47968c54590203e89a6614e61020d3 Mon Sep 17 00:00:00 2001 From: James McCoy Date: Mon, 14 Nov 2016 10:19:06 -0500 Subject: vim-patch:7.4.1658 Problem: A plugin does not know when VimEnter autocommands were already triggered. Solution: Add the v:vim_did_enter variable. https://github.com/vim/vim/commit/1473551a4457d4920b235eeeb9f279e196ee7225 --- test/functional/autocmd/autocmd_spec.lua | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'test') diff --git a/test/functional/autocmd/autocmd_spec.lua b/test/functional/autocmd/autocmd_spec.lua index 72aff58d73..162e112047 100644 --- a/test/functional/autocmd/autocmd_spec.lua +++ b/test/functional/autocmd/autocmd_spec.lua @@ -2,6 +2,7 @@ local helpers = require('test.functional.helpers')(after_each) local clear = helpers.clear local command = helpers.command +local eq = helpers.eq local eval = helpers.eval describe('autocmds:', function() @@ -28,4 +29,8 @@ describe('autocmds:', function() command('tabnew') assert.same(expected, eval('g:foo')) end) + + it('v:vim_did_enter is 1 after VimEnter', function() + eq(1, eval('v:vim_did_enter')) + end) end) -- cgit