diff options
Diffstat (limited to 'src/testdir/test_cindent.vim')
-rw-r--r-- | src/testdir/test_cindent.vim | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/src/testdir/test_cindent.vim b/src/testdir/test_cindent.vim index 9258192897..dc8c51dbfe 100644 --- a/src/testdir/test_cindent.vim +++ b/src/testdir/test_cindent.vim @@ -5272,4 +5272,40 @@ func Test_cindent_change_multline() close! endfunc +func Test_cindent_pragma() + new + setl cindent ts=4 sw=4 + setl cino=Ps + + let code =<< trim [CODE] + { + #pragma omp parallel + { + #pragma omp task + foo(); + # pragma omp taskwait + } + } + [CODE] + + call append(0, code) + normal gg + normal =G + + let expected =<< trim [CODE] + { + #pragma omp parallel + { + #pragma omp task + foo(); + # pragma omp taskwait + } + } + + [CODE] + + call assert_equal(expected, getline(1, '$')) + enew! | close +endfunc + " vim: shiftwidth=2 sts=2 expandtab |