2014-05-15 18 views
1

所以我設置了RubyTest/Sublime Text 3並且工作正常。我在SpringTest中遇到了麻煩。有這個神祕的設置:Sublime Text 3,rbenv,TestUnit,RubyTest和Spring正確的配置讓測試工作

"check_for_spring": false, 

但是,當我設置爲true,並運行測試它只是給我的默認春天命令的輸出如:

Version: 1.1.3 

Usage: spring COMMAND [ARGS] 

Commands for spring itself: 

如果我按照這個網址的信息(https://github.com/rails/spring ),調用測試的正確方法是?

bin/rake test test/functional/posts_controller_test.rb 

現在我的測試運行電流設置爲:

"run_ruby_unit_command": "ruby -Itest {relative_path}", 
"run_single_ruby_unit_command": "ruby -Itest {relative_path} -n '{test_name}'", 

如果我嘗試chaning到:

bin/rake test 

這不起作用,給人以命令沒有發現錯誤,即使我複製/粘貼命令路徑,它在shell中工作。

我出來的想法幫助!

回答

1

這將這樣的伎倆

"run_ruby_unit_command": "export PATH=~/.rbenv/shims:$PATH; bin/rake test -Itest {relative_path}", 
"run_single_ruby_unit_command": "export PATH=~/.rbenv/shims:$PATH; bin/rake test {relative_path} {test_name}", 
1

我用這個

"run_ruby_unit_command": "spring rake test {relative_path}", 
"run_single_ruby_unit_command": "spring rake test {relative_path} {test_name}" 
相關問題