From bd122494cc3012a4885a55663e7c158c7a402878 Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Thu, 27 Oct 2022 08:26:09 +0800 Subject: vim-patch:8.2.2100: insufficient testing for function range and dict MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Problem: Insufficient testing for function range and dict. Solution: Add a few tests. (Dominique Pellé, closes vim/vim#7428) https://github.com/vim/vim/commit/67322bf74a106b6476b093e75da87d61e2181b76 --- src/nvim/testdir/test_lambda.vim | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/nvim/testdir/test_lambda.vim') diff --git a/src/nvim/testdir/test_lambda.vim b/src/nvim/testdir/test_lambda.vim index 3c12c7b02e..ce15243993 100644 --- a/src/nvim/testdir/test_lambda.vim +++ b/src/nvim/testdir/test_lambda.vim @@ -245,6 +245,11 @@ func Test_closure_counter() call assert_equal(2, l:F()) call assert_equal(3, l:F()) call assert_equal(4, l:F()) + + call assert_match("^\n function \\d\\+_bar() closure" + \ .. "\n1 let x += 1" + \ .. "\n2 return x" + \ .. "\n endfunction$", execute('func s:bar')) endfunc func Test_closure_unlet() -- cgit