Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

- Added alias tests.

  • Loading branch information...
commit 4878d5ca9b220bbb87c32e4470ef8b25f32dec92 1 parent 76381f9
@Shougo authored
View
4 autoload/vimshell/parser.vim
@@ -1,7 +1,7 @@
"=============================================================================
" FILE: parser.vim
" AUTHOR: Shougo Matsushita <Shougo.Matsu@gmail.com>
-" Last Modified: 15 Jul 2012.
+" Last Modified: 22 Jul 2012.
" License: MIT license {{{
" Permission is hereby granted, free of charge, to any person obtaining
" a copy of this software and associated documentation files (the
@@ -397,7 +397,7 @@ function! s:recursive_expand_alias(alias_name, args)"{{{
endwhile
endtry
- if script ==# alias
+ if script ==# alias && !empty(a:args)
let script .= ' ' . join(a:args)
endif
View
1  doc/vimshell.txt
@@ -1308,6 +1308,7 @@ CHANGELOG *vimshell-changelog*
- Improved prompt syntax.
- Improved vimshell prompt behavior.
- Added prompts options.
+- Added alias tests.
2012-07-18
- Improved interrupt behavior.
View
26 vest/parser.vim
@@ -0,0 +1,26 @@
+" Tests for vimshell.
+
+scriptencoding utf-8
+
+" Saving 'cpoptions' {{{
+let s:save_cpo = &cpo
+set cpo&vim
+" }}}
+
+Context Vesting.run()
+ It tests aliases.
+ VimShellCreate
+ call vimshell#set_alias('l2', 'll')
+ call vimshell#set_alias('ll', 'ls -l')
+ Should vimshell#parser#parse_alias('l2') ==# 'ls -l'
+ VimShellCreate -toggle
+ End
+End
+
+Fin
+
+" Restore 'cpoptions' {{{
+let &cpo = s:save_cpo
+" }}}
+
+" vim:foldmethod=marker:fen:
Please sign in to comment.
Something went wrong with that request. Please try again.