comparison src/testdir/test_execute_func.vim @ 19249:2a017e9dc6da v8.2.0183

patch 8.2.0183: tests fail when the float feature is disabled Commit: https://github.com/vim/vim/commit/5feabe00c47fa66d5f4c95213f150488433f78e3 Author: Bram Moolenaar <Bram@vim.org> Date: Thu Jan 30 18:24:53 2020 +0100 patch 8.2.0183: tests fail when the float feature is disabled Problem: Tests fail when the float feature is disabled. Solution: Skip tests that don't work without float support.
author Bram Moolenaar <Bram@vim.org>
date Thu, 30 Jan 2020 18:30:04 +0100
parents fd1070ff696b
children 49694eceaa55
comparison
equal deleted inserted replaced
19248:5e803caf5e9c 19249:2a017e9dc6da
28 redir END 28 redir END
29 call assert_equal("\nthis\ntheend", redired) 29 call assert_equal("\nthis\ntheend", redired)
30 call assert_equal("\nthat", evaled) 30 call assert_equal("\nthat", evaled)
31 31
32 call assert_fails('call execute("doesnotexist")', 'E492:') 32 call assert_fails('call execute("doesnotexist")', 'E492:')
33 call assert_fails('call execute(3.4)', 'E806:')
34 call assert_fails('call execute("call NestedRedir()")', 'E930:') 33 call assert_fails('call execute("call NestedRedir()")', 'E930:')
35 34
36 call assert_equal("\nsomething", execute('echo "something"', '')) 35 call assert_equal("\nsomething", execute('echo "something"', ''))
37 call assert_equal("\nsomething", execute('echo "something"', 'silent')) 36 call assert_equal("\nsomething", execute('echo "something"', 'silent'))
38 call assert_equal("\nsomething", execute('echo "something"', 'silent!')) 37 call assert_equal("\nsomething", execute('echo "something"', 'silent!'))
39 call assert_equal("", execute('burp', 'silent!')) 38 call assert_equal("", execute('burp', 'silent!'))
40 call assert_fails('call execute("echo \"x\"", 3.4)', 'E806:') 39 if has('float')
40 call assert_fails('call execute(3.4)', 'E806:')
41 call assert_fails('call execute("echo \"x\"", 3.4)', 'E806:')
42 endif
41 endfunc 43 endfunc
42 44
43 func Test_execute_list() 45 func Test_execute_list()
44 call assert_equal("\nsomething\nnice", execute(['echo "something"', 'echo "nice"'])) 46 call assert_equal("\nsomething\nnice", execute(['echo "something"', 'echo "nice"']))
45 let l = ['for n in range(0, 3)', 47 let l = ['for n in range(0, 3)',