Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge pull request #16 from raskchanky/master

Making the spec command configurable
  • Loading branch information...
commit 3152773ee84d704c0bde572e3efe10d3cb51ee4e 2 parents 70a7143 + 0f33a85
@skalnik authored
Showing with 12 additions and 1 deletion.
  1. +1 −0  .gitignore
  2. +6 −1 autoload/vroom.vim
  3. +5 −0 doc/vroom.txt
View
1  .gitignore
@@ -0,0 +1 @@
+doc/tags
View
7 autoload/vroom.vim
@@ -4,6 +4,10 @@ if exists("g:loaded_vroom") || &cp
endif
let g:loaded_vroom = 1
+if !exists("g:vroom_spec_command")
+ let g:vroom_spec_command = 'rspec '
+endif
+
if !exists("g:vroom_use_colors")
let g:vroom_use_colors = !has('gui_running')
endif
@@ -98,7 +102,8 @@ function s:RunTests(filename)
call s:SetColorFlag()
" Run the right test for the given file
if match(a:filename, '_spec.rb') != -1
- call s:Run(s:test_runner_prefix ."rspec " . a:filename . s:color_flag)
+" call s:Run(s:test_runner_prefix ."rspec " . a:filename . s:color_flag)
+ call s:Run(s:test_runner_prefix .g:vroom_spec_command . a:filename . s:color_flag)
elseif match(a:filename, '\.feature') != -1
call s:Run(s:test_runner_prefix .g:vroom_cucumber_path . a:filename . s:color_flag)
elseif match(a:filename, "_test.rb") != -1
View
5 doc/vroom.txt
@@ -100,6 +100,11 @@ g:vroom_binstubs_path *vroom_binstubs_path*
automatically and should not be included.
Default: './bin'
+g:vroom_spec_command *vroom_spec_command*
+ This lets you specify the command that runs your
+ specs, e.g. for rspec 1.x, you can use 'spec '.
+ Default: 'rspec '
+
===============================================================================
LICENSE *vroom-license*
Please sign in to comment.
Something went wrong with that request. Please try again.