diff options
author | Thiago de Arruda <tpadilha84@gmail.com> | 2015-01-21 18:45:24 -0300 |
---|---|---|
committer | Thiago de Arruda <tpadilha84@gmail.com> | 2015-01-22 08:54:42 -0300 |
commit | 5b65ac2ca7995248eafbbc78abc1645dc93b636b (patch) | |
tree | d84fbf3937a056c7d3f54d7797706b05fb66d7e2 | |
parent | f08fe552f463475f60444fc7f9df982e8f81baf0 (diff) | |
download | rneovim-5b65ac2ca7995248eafbbc78abc1645dc93b636b.tar.gz rneovim-5b65ac2ca7995248eafbbc78abc1645dc93b636b.tar.bz2 rneovim-5b65ac2ca7995248eafbbc78abc1645dc93b636b.zip |
test: Make it possible to run functional tests with plain lua
Replace the hexadecimal escape sequences, which are only supported by luajit
-rw-r--r-- | test/functional/api/vim_spec.lua | 2 | ||||
-rw-r--r-- | test/functional/clipboard/clipboard_provider_spec.lua | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/test/functional/api/vim_spec.lua b/test/functional/api/vim_spec.lua index 2c17a2acd0..bee9c18bd8 100644 --- a/test/functional/api/vim_spec.lua +++ b/test/functional/api/vim_spec.lua @@ -117,7 +117,7 @@ describe('vim_* functions', function() describe('replace_termcodes', function() it('escapes K_SPECIAL as K_SPECIAL KS_SPECIAL KE_FILLER', function() - eq(helpers.nvim('replace_termcodes', '\x80', true, true, true), '\x80\xfeX') + eq(helpers.nvim('replace_termcodes', '\128', true, true, true), '\128\254X') end) it('leaves non K_SPECIAL string unchanged', function() diff --git a/test/functional/clipboard/clipboard_provider_spec.lua b/test/functional/clipboard/clipboard_provider_spec.lua index ccbb74e487..c412c26c1a 100644 --- a/test/functional/clipboard/clipboard_provider_spec.lua +++ b/test/functional/clipboard/clipboard_provider_spec.lua @@ -72,10 +72,10 @@ describe('clipboard usage', function() reset() -- handle null bytes - insert("some\x16000text\n\x16000very binary\x16000") + insert("some\022000text\n\022000very binary\022000") feed('"*y-+"*p') eq({'some\ntext', '\nvery binary\n',''}, eval("g:test_clip['*']")) - expect("some\x00text\n\x00very binary\x00\nsome\x00text\n\x00very binary\x00") + expect("some\00text\n\00very binary\00\nsome\00text\n\00very binary\00") -- test getreg/getregtype eq('some\ntext\n\nvery binary\n\n', eval("getreg('*', 1)")) @@ -92,7 +92,7 @@ describe('clipboard usage', function() expect([[ very much blocktext]]) - eq("\x165", eval("getregtype('*')")) + eq("\0225", eval("getregtype('*')")) reset() -- test setreg |