mirror of
https://github.com/neovim/neovim.git
synced 2025-11-22 10:06:33 +00:00
vim-patch:8.0.1510: cannot assert beep #9938
Problem: Cannot test if a command causes a beep.
Solution: Add assert_beeps().
b48e96f61c
This commit is contained in:
committed by
Justin M. Keyes
parent
24a9516ff4
commit
9d77a07686
@@ -18,6 +18,15 @@ describe('assert function:', function()
|
||||
clear()
|
||||
end)
|
||||
|
||||
describe('assert_beeps', function()
|
||||
it('works', function()
|
||||
call('assert_beeps', 'normal h')
|
||||
expected_empty()
|
||||
call('assert_beeps', 'normal 0')
|
||||
expected_errors({'command did not beep: normal 0'})
|
||||
end)
|
||||
end)
|
||||
|
||||
-- assert_equal({expected}, {actual}, [, {msg}])
|
||||
describe('assert_equal', function()
|
||||
it('should not change v:errors when expected is equal to actual', function()
|
||||
|
||||
Reference in New Issue
Block a user