diff options
author | Bram Moolenaar <Bram@vim.org> | 2019-06-24 00:58:07 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2019-06-24 00:58:07 +0200 |
commit | e7eb92708ec2092a2fc11e78703b5dcf83844412 (patch) | |
tree | d00da20838b81404557c7b0ef17d2890f18175ac /src/testdir/test_normal.vim | |
parent | 0a1f56fcfe31be929e9cd8c3d81a984c960e4180 (diff) |
patch 8.1.1585: :let-heredoc does not trim enoughv8.1.1585
Problem: :let-heredoc does not trim enough.
Solution: Trim indent from the contents based on the indent of the first
line. Use let-heredoc in more tests.
Diffstat (limited to 'src/testdir/test_normal.vim')
-rw-r--r-- | src/testdir/test_normal.vim | 182 |
1 files changed, 91 insertions, 91 deletions
diff --git a/src/testdir/test_normal.vim b/src/testdir/test_normal.vim index 48857927c8..a9fe46a22a 100644 --- a/src/testdir/test_normal.vim +++ b/src/testdir/test_normal.vim @@ -1556,34 +1556,34 @@ endfunc fun! Test_normal29_brace() " basic test for { and } movements let text =<< trim [DATA] - A paragraph begins after each empty line, and also at each of a set of - paragraph macros, specified by the pairs of characters in the 'paragraphs' - option. The default is "IPLPPPQPP TPHPLIPpLpItpplpipbp", which corresponds to - the macros ".IP", ".LP", etc. (These are nroff macros, so the dot must be in - the first column). A section boundary is also a paragraph boundary. - Note that a blank line (only containing white space) is NOT a paragraph - boundary. - - - Also note that this does not include a '{' or '}' in the first column. When - the '{' flag is in 'cpoptions' then '{' in the first column is used as a - paragraph boundary |posix|. - { - This is no paragraph - unless the '{' is set - in 'cpoptions' - } - .IP - The nroff macros IP separates a paragraph - That means, it must be a '.' - followed by IP - .LPIt does not matter, if afterwards some - more characters follow. - .SHAlso section boundaries from the nroff - macros terminate a paragraph. That means - a character like this: - .NH - End of text here + A paragraph begins after each empty line, and also at each of a set of + paragraph macros, specified by the pairs of characters in the 'paragraphs' + option. The default is "IPLPPPQPP TPHPLIPpLpItpplpipbp", which corresponds to + the macros ".IP", ".LP", etc. (These are nroff macros, so the dot must be in + the first column). A section boundary is also a paragraph boundary. + Note that a blank line (only containing white space) is NOT a paragraph + boundary. + + + Also note that this does not include a '{' or '}' in the first column. When + the '{' flag is in 'cpoptions' then '{' in the first column is used as a + paragraph boundary |posix|. + { + This is no paragraph + unless the '{' is set + in 'cpoptions' + } + .IP + The nroff macros IP separates a paragraph + That means, it must be a '.' + followed by IP + .LPIt does not matter, if afterwards some + more characters follow. + .SHAlso section boundaries from the nroff + macros terminate a paragraph. That means + a character like this: + .NH + End of text here [DATA] new @@ -1592,17 +1592,17 @@ fun! Test_normal29_brace() norm! 0d2} let expected =<< trim [DATA] - .IP - The nroff macros IP separates a paragraph - That means, it must be a '.' - followed by IP - .LPIt does not matter, if afterwards some - more characters follow. - .SHAlso section boundaries from the nroff - macros terminate a paragraph. That means - a character like this: - .NH - End of text here + .IP + The nroff macros IP separates a paragraph + That means, it must be a '.' + followed by IP + .LPIt does not matter, if afterwards some + more characters follow. + .SHAlso section boundaries from the nroff + macros terminate a paragraph. That means + a character like this: + .NH + End of text here [DATA] call assert_equal(expected, getline(1, '$')) @@ -1610,14 +1610,14 @@ fun! Test_normal29_brace() norm! 0d} let expected =<< trim [DATA] - .LPIt does not matter, if afterwards some - more characters follow. - .SHAlso section boundaries from the nroff - macros terminate a paragraph. That means - a character like this: - .NH - End of text here - + .LPIt does not matter, if afterwards some + more characters follow. + .SHAlso section boundaries from the nroff + macros terminate a paragraph. That means + a character like this: + .NH + End of text here + [DATA] call assert_equal(expected, getline(1, '$')) @@ -1625,11 +1625,11 @@ fun! Test_normal29_brace() norm! d{ let expected =<< trim [DATA] - .LPIt does not matter, if afterwards some - more characters follow. - .SHAlso section boundaries from the nroff - macros terminate a paragraph. That means - a character like this: + .LPIt does not matter, if afterwards some + more characters follow. + .SHAlso section boundaries from the nroff + macros terminate a paragraph. That means + a character like this: [DATA] call assert_equal(expected, getline(1, '$')) @@ -1637,8 +1637,8 @@ fun! Test_normal29_brace() norm! d{ let expected =<< trim [DATA] - .LPIt does not matter, if afterwards some - more characters follow. + .LPIt does not matter, if afterwards some + more characters follow. [DATA] call assert_equal(expected, getline(1, '$')) @@ -1651,22 +1651,22 @@ fun! Test_normal29_brace() norm! 0d2} let expected =<< trim [DATA] - { - This is no paragraph - unless the '{' is set - in 'cpoptions' - } - .IP - The nroff macros IP separates a paragraph - That means, it must be a '.' - followed by IP - .LPIt does not matter, if afterwards some - more characters follow. - .SHAlso section boundaries from the nroff - macros terminate a paragraph. That means - a character like this: - .NH - End of text here + { + This is no paragraph + unless the '{' is set + in 'cpoptions' + } + .IP + The nroff macros IP separates a paragraph + That means, it must be a '.' + followed by IP + .LPIt does not matter, if afterwards some + more characters follow. + .SHAlso section boundaries from the nroff + macros terminate a paragraph. That means + a character like this: + .NH + End of text here [DATA] call assert_equal(expected, getline(1, '$')) @@ -1675,22 +1675,22 @@ fun! Test_normal29_brace() norm! d} let expected =<< trim [DATA] - { - This is no paragraph - unless the '{' is set - in 'cpoptions' - } - .IP - The nroff macros IP separates a paragraph - That means, it must be a '.' - followed by IP - .LPIt does not matter, if afterwards some - more characters follow. - .SHAlso section boundaries from the nroff - macros terminate a paragraph. That means - a character like this: - .NH - End of text here + { + This is no paragraph + unless the '{' is set + in 'cpoptions' + } + .IP + The nroff macros IP separates a paragraph + That means, it must be a '.' + followed by IP + .LPIt does not matter, if afterwards some + more characters follow. + .SHAlso section boundaries from the nroff + macros terminate a paragraph. That means + a character like this: + .NH + End of text here [DATA] call assert_equal(expected, getline(1, '$')) @@ -1699,11 +1699,11 @@ fun! Test_normal29_brace() norm! d5} let expected =<< trim [DATA] - { - This is no paragraph - unless the '{' is set - in 'cpoptions' - } + { + This is no paragraph + unless the '{' is set + in 'cpoptions' + } [DATA] call assert_equal(expected, getline(1, '$')) |