Permalink
Browse files

Add some juggler tests

  • Loading branch information...
1 parent e260539 commit 4fdc82a7dce4203f0122d340c4cf01151d032168 @sjbach committed Jun 26, 2010
File renamed without changes.
@@ -0,0 +1,35 @@
+spawn vim -N --noplugin -u ../vimrc
+set timeout 3
+expect {
+ timeout {exit 1}
+ "VIM - Vi IMproved"
+}
+send ":e file-name-abc\r"
+send ":e file-name-def\r"
+send ":LustyJuggler\r"
+# Launching should not have caused a backtrace and "Press ENTER ..." message
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "file-name-abc"
+}
+
+# Choose and open second entry
+send "ss"
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "inside abc"
+}
+
+send ":q\r"
+expect {
+ timeout {exit 1}
+ eof
+}
+exit 0
+
@@ -0,0 +1 @@
+inside abc
@@ -0,0 +1 @@
+inside def
@@ -0,0 +1,85 @@
+spawn vim -N --noplugin -u ../vimrc
+set timeout 3
+expect {
+ timeout {exit 1}
+ "VIM - Vi IMproved"
+}
+
+# Open >10 files
+send ":e file-name-abc\r"
+send ":e file-name-def\r"
+send ":e file-name-ghi\r"
+send ":e file-name-jkl\r"
+send ":e file-name-mno\r"
+send ":e file-name-pqr\r"
+send ":e file-name-stu\r"
+send ":e file-name-vwx\r"
+send ":e file-name-yza\r"
+send ":e file-name-bcd\r"
+send ":e file-name-efg\r"
+send ":e file-name-hij\r"
+
+send ":LustyJuggler\r"
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "file-name-hij"
+}
+
+# Choose and open last entry
+send ";;"
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "\"file-name-ghi\""
+}
+
+send ":LustyJuggler\r"
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "file-name-hij"
+}
+
+# Choose and open last entry
+send ";;"
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "\"file-name-jkl\""
+}
+
+send ":LustyJuggler\r"
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "file-name-hij"
+}
+
+# Choose and open sixth entry
+send "hh"
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "\"file-name-yza\""
+}
+
+send ":q\r"
+expect {
+ timeout {exit 1}
+ eof
+}
+exit 0
+
@@ -0,0 +1 @@
+inside abc
@@ -0,0 +1 @@
+inside bcd
@@ -0,0 +1 @@
+inside def
@@ -0,0 +1 @@
+inside efg
@@ -0,0 +1 @@
+inside ghi
@@ -0,0 +1 @@
+inside hij
@@ -0,0 +1 @@
+inside jkl
@@ -0,0 +1 @@
+inside mno
@@ -0,0 +1 @@
+inside pqr
@@ -0,0 +1 @@
+inside stu
@@ -0,0 +1 @@
+inside vwx
@@ -0,0 +1 @@
+inside yza
@@ -0,0 +1,23 @@
+spawn vim -N --noplugin -u ../vimrc
+set timeout 3
+expect {
+ timeout {exit 1}
+ "VIM - Vi IMproved"
+}
+send ":LustyJuggler\r"
+# Launching should not have caused a backtrace and "Press ENTER ..." message
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "No other buffers"
+}
+
+send ":q\r"
+expect {
+ timeout {exit 1}
+ eof
+}
+exit 0
+
@@ -0,0 +1,35 @@
+spawn vim -N --noplugin -u ../vimrc
+set timeout 3
+expect {
+ timeout {exit 1}
+ "VIM - Vi IMproved"
+}
+send ":e file-name-abc\r"
+send ":e file-name-def\r"
+send ":LustyJuggler\r"
+# Launching should not have caused a backtrace and "Press ENTER ..." message
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "file-name-abc"
+}
+
+# Choose and open second entry
+send "22"
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "inside abc"
+}
+
+send ":q\r"
+expect {
+ timeout {exit 1}
+ eof
+}
+exit 0
+
@@ -0,0 +1 @@
+inside abc
@@ -0,0 +1 @@
+inside def
@@ -0,0 +1,35 @@
+spawn vim -N --noplugin -u ../vimrc
+set timeout 3
+expect {
+ timeout {exit 1}
+ "VIM - Vi IMproved"
+}
+send ":e file-name-abc\r"
+send ":e file-name-def\r"
+send ":LustyJuggler\r"
+# Launching should not have caused a backtrace and "Press ENTER ..." message
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "file-name-abc"
+}
+
+# Choose and open 10th entry -- should be second entry.
+send ";;"
+expect {
+ "Press ENTER" {exit 1}
+ "Error" {exit 1}
+ "Warning" {exit 1}
+ timeout {exit 1}
+ "inside abc"
+}
+
+send ":q\r"
+expect {
+ timeout {exit 1}
+ eof
+}
+exit 0
+
@@ -0,0 +1 @@
+inside abc
@@ -0,0 +1 @@
+inside def
@@ -4,9 +4,9 @@ expect {
timeout {exit 1}
"VIM - Vi IMproved"
}
-send ":e abc\r"
-send ":e dir/abc\r"
-send ":e dir/def\r"
+send ":e abc\r"
+send ":e dir/abc\r"
+send ":e dir/def\r"
expect {
"Press ENTER" {exit 1}
"Error" {exit 1}
View
@@ -4,6 +4,7 @@ set nobackup
set noswapfile
source ../../plugin/lusty-explorer.vim
+source ../../plugin/lusty-juggler.vim
" Not too useful because a bug in Vim causes an E15 error
" whenever a Ruby plugin is called. :-(

0 comments on commit 4fdc82a

Please sign in to comment.