Ver código fonte

Tests: reorganization

Marco Hinz 10 anos atrás
pai
commit
c742c3a752
5 arquivos alterados com 29 adições e 22 exclusões
  1. 2 2
      README.md
  2. 2 19
      test/feature/buffer.vader
  3. 19 0
      test/feature/mappings.vader
  4. 1 1
      test/run
  5. 5 0
      test/vader.vader

+ 2 - 2
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.

+ 2 - 19
test/tests.vader → 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

+ 19 - 0
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

+ 1 - 1
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'

+ 5 - 0
test/vader.vader

@@ -0,0 +1,5 @@
+Execute (:Startify command available):
+  Assert 2 == exists(':Startify')
+
+Include: feature/buffer.vader
+Include: feature/mappings.vader