comparison src/testdir/test_popupwin.vim @ 32741:19a9b8fe3b85 v9.0.1690

patch 9.0.1690: popup_create() not aborting on errors Commit: https://github.com/vim/vim/commit/f6cdab3704959379086d6a097fabdf6c55d73779 Author: Christian Brabandt <cb@256bit.org> Date: Fri Aug 11 23:42:02 2023 +0200 patch 9.0.1690: popup_create() not aborting on errors Problem: popup_create() not aborting on errors Solution: check for errors in arguments given and abort if an error occurred closes: #12711 Signed-off-by: Christian Brabandt <cb@256bit.org>
author Christian Brabandt <cb@256bit.org>
date Sat, 12 Aug 2023 00:00:03 +0200
parents 84bda983ee01
children abf161ce0c77
comparison
equal deleted inserted replaced
32740:a59357132983 32741:19a9b8fe3b85
4177 4177
4178 " clean up 4178 " clean up
4179 call StopVimInTerminal(buf) 4179 call StopVimInTerminal(buf)
4180 endfunc 4180 endfunc
4181 4181
4182 func Test_popupwin_with_error()
4183 CheckScreendump
4184
4185 let lines =<< trim END
4186 let options = {'border': 'ERROR', 'line': 1, 'col': 1, 'minwidth': &columns, 'title': 'TITLE'}
4187
4188 END
4189 "call popup_create('Hello world!', options)
4190 call writefile(lines, 'XtestPopupError', 'D')
4191 let buf = RunVimInTerminal('-S XtestPopupError', {})
4192 call term_sendkeys(buf, ":call popup_create('Hello world!', options)\<CR>")
4193 call VerifyScreenDump(buf, 'Test_popupwin_with_error_1', {})
4194
4195 " clean up
4196 call StopVimInTerminal(buf)
4197 endfunc
4198
4182 4199
4183 " vim: shiftwidth=2 sts=2 4200 " vim: shiftwidth=2 sts=2