From 7f61ab3a497224210914c44c16c73046364a24a3 Mon Sep 17 00:00:00 2001 From: Hiroshi Shirosaki Date: Tue, 8 Dec 2015 15:36:34 +0900 Subject: [PATCH 1/1] Move test/folding.md to test/folding.vader Fix #73 --- test/folding.md | 16 ---------------- test/folding.vader | 38 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+), 16 deletions(-) delete mode 100644 test/folding.md create mode 100644 test/folding.vader diff --git a/test/folding.md b/test/folding.md deleted file mode 100644 index 09ede4d..0000000 --- a/test/folding.md +++ /dev/null @@ -1,16 +0,0 @@ -# Title - -## Chapter 1 - -``` -This is code block -# This is just a comment -``` - -## Capter 2 - -foobar - -==+ Fold Level 1 - ---+ Fold Level 2 diff --git a/test/folding.vader b/test/folding.vader new file mode 100644 index 0000000..ee20975 --- /dev/null +++ b/test/folding.vader @@ -0,0 +1,38 @@ +Before: + source ../after/ftplugin/markdown.vim + +After: + setlocal foldexpr=0 + setlocal foldmethod=manual + +Given markdown; +# Title + +## Chapter 1 + +``` +This is code block +# This is just a comment +``` + +## Capter 2 + +foobar + +Execute (fold level # in code block): + AssertEqual foldlevel(1), 0, '# Title' + AssertEqual foldlevel(3), 1, '## Chapter 1' + AssertEqual foldlevel(7), 2, '# This is just a comment' + AssertEqual foldlevel(8), 2, '```' + AssertEqual foldlevel(10), 1, '## Chapter 2' + AssertEqual foldlevel(12), 2, 'foobar' + +Given markdown; + +==+ Fold Level 1 + +--+ Fold Level 2 + +Execute (fold level ==+, --+): + AssertEqual foldlevel(2), 1, '==+' + AssertEqual foldlevel(4), 2, '--+' -- 2.39.5