From c742c3a752b928ac1949cffb684f057da8c76679 Mon Sep 17 00:00:00 2001 From: Marco Hinz Date: Tue, 2 Feb 2016 12:25:39 +0100 Subject: [PATCH] Tests: reorganization --- README.md | 4 ++-- test/{tests.vader => feature/buffer.vader} | 21 ++------------------- test/feature/mappings.vader | 19 +++++++++++++++++++ test/run | 2 +- test/vader.vader | 5 +++++ 5 files changed, 29 insertions(+), 22 deletions(-) rename test/{tests.vader => feature/buffer.vader} (54%) create mode 100644 test/feature/mappings.vader create mode 100644 test/vader.vader diff --git a/README.md b/README.md index 5287d91..a4c98d8 100644 --- a/README.md +++ b/README.md @@ -9,8 +9,8 @@ This plugin provides a start screen for Vim and Neovim. It provides **dynamically created headers or footers** and uses configurable lists to show **recently used or bookmarked files** and **persistent sessions**. -All of this can be accessed in a **simple to use menu** that allows to open -single or multiple entries. +All of this can be accessed in a **simple to use menu** that even allows to +**open multiple entries** at once. Startify doesn't get in your way and works out-of-the-box, but provides many options for fine-grained customization. diff --git a/test/tests.vader b/test/feature/buffer.vader similarity index 54% rename from test/tests.vader rename to test/feature/buffer.vader index 14c526e..91a7b34 100644 --- a/test/tests.vader +++ b/test/feature/buffer.vader @@ -1,7 +1,7 @@ -Before (check :Startify): +Before: Startify -Execute (check options): +Execute (Check set options): AssertEqual 'startify', &filetype AssertEqual 'wipe', &bufhidden AssertEqual 'nofile', &buftype @@ -11,20 +11,3 @@ Execute (check options): AssertEqual 0, &list AssertEqual 0, &number AssertEqual 0, &swapfile - -Do (open new buffer in insert mode via 'i'): - ifoo -Expect (only "foo"): - foo - -Do (open new buffer in normal mode via 'e'): - eibar -Expect (only "bar"): - bar - -Given: - quux -Do (quit startify buffer via 'q'): - q -Expect: - quux diff --git a/test/feature/mappings.vader b/test/feature/mappings.vader new file mode 100644 index 0000000..3d4d2e9 --- /dev/null +++ b/test/feature/mappings.vader @@ -0,0 +1,19 @@ +Before: + Startify + +Do (Open new buffer in insert "foo"): + ifoo +Expect (Buffer contains only "foo"): + foo + +Do (Open new buffer in normal mode and insert "bar"): + eibar +Expect (Buffer contains only "bar"): + bar + +Given (Buffer that contains only "quux"): + quux +Do (Quit Startify buffer via 'q'): + q +Expect (Buffer before :Startify was called): + quux diff --git a/test/run b/test/run index f7c67c0..f547d2f 100755 --- a/test/run +++ b/test/run @@ -21,4 +21,4 @@ cp viminfo viminfo.tmp trap "{ rm viminfo.tmp; }" EXIT echo '(Be patient.. testing can take a while.)' -HOME=/dev/null vim -XNu vimrc -i viminfo.tmp -c 'Vader! *' +HOME=/dev/null vim -XNu vimrc -i viminfo.tmp -c 'Vader! vader.vader' diff --git a/test/vader.vader b/test/vader.vader new file mode 100644 index 0000000..61a536a --- /dev/null +++ b/test/vader.vader @@ -0,0 +1,5 @@ +Execute (:Startify command available): + Assert 2 == exists(':Startify') + +Include: feature/buffer.vader +Include: feature/mappings.vader