From 7fc5d6fc8e9bc4f03c2adeea04a6d3c0c2cdc9a3 Mon Sep 17 00:00:00 2001 From: Rainer Borene Date: Sat, 8 Nov 2014 17:08:42 -0200 Subject: legacy tests: migrate test66 --- .../legacy/066_visual_block_tab_spec.lua | 64 ++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 test/functional/legacy/066_visual_block_tab_spec.lua (limited to 'test/functional/legacy/066_visual_block_tab_spec.lua') diff --git a/test/functional/legacy/066_visual_block_tab_spec.lua b/test/functional/legacy/066_visual_block_tab_spec.lua new file mode 100644 index 0000000000..cd283e6746 --- /dev/null +++ b/test/functional/legacy/066_visual_block_tab_spec.lua @@ -0,0 +1,64 @@ +-- vim: set foldmethod=marker foldmarker=[[,]] : +-- Test for visual block shift and tab characters. + +local helpers = require('test.functional.helpers') +local clear, feed, insert = helpers.clear, helpers.feed, helpers.insert +local execute, expect = helpers.execute, helpers.expect + +describe('visual block shift and tab characters', function() + setup(clear) + + it('is working', function() + insert([[ + one two three + one two three + one two three + one two three + one two three + + abcdefghijklmnopqrstuvwxyz + abcdefghijklmnopqrstuvwxyz + abcdefghijklmnopqrstuvwxyz + abcdefghijklmnopqrstuvwxyz + abcdefghijklmnopqrstuvwxyz]]) + + feed('gg') + feed([[fe4jRugvr1:'<,'>yank A]]) + execute('/^abcdefgh') + feed('4jI j<<11|D') + feed('j7|a ') + feed('j7|a ') + feed('j7|a 4k13|4j<') + execute('$-5,$yank A') + execute([[$-4,$s/\s\+//g]]) + feed('4kI j<<') + feed('j7|a ') + feed('j7|a ') + feed('j7|a 4k13|4j3<') + execute('$-4,$yank A') + + -- Put @a and clean empty lines + execute('%d') + execute('0put a') + execute('$d') + + -- Assert buffer contents. + expect([[ + on1 two three + on1 two three + on1 two three + on1 two three + on1 two three + + abcdefghijklmnopqrstuvwxyz + abcdefghij + abc defghijklmnopqrstuvwxyz + abc defghijklmnopqrstuvwxyz + abc defghijklmnopqrstuvwxyz + abcdefghijklmnopqrstuvwxyz + abcdefghij + abc defghijklmnopqrstuvwxyz + abc defghijklmnopqrstuvwxyz + abc defghijklmnopqrstuvwxyz]]) + end) +end) -- cgit