digraph_spec.lua 694 B

123456789101112131415161718192021222324252627282930313233
  1. local n = require('test.functional.testnvim')()
  2. local Screen = require('test.functional.ui.screen')
  3. local clear = n.clear
  4. local feed = n.feed
  5. before_each(clear)
  6. describe('digraph', function()
  7. -- oldtest: Test_entering_digraph()
  8. it('characters displayed on the screen', function()
  9. local screen = Screen.new(10, 6)
  10. feed('i<C-K>')
  11. screen:expect([[
  12. {18:^?} |
  13. {1:~ }|*4
  14. {5:-- INSERT --}|
  15. ]])
  16. feed('1')
  17. screen:expect([[
  18. {18:^1} |
  19. {1:~ }|*4
  20. {5:-- INSERT --}|
  21. ]])
  22. feed('2')
  23. screen:expect([[
  24. ½^ |
  25. {1:~ }|*4
  26. {5:-- INSERT --}|
  27. ]])
  28. end)
  29. end)