å°ããã¤RSpec on Railsã«ç§»è¡ãã¦ãããã¨ãã¦ããã ãã©ã Test::Unitã¨éã£ã¦rails.vimã®ãµãã¼ãããªãã¦ç°¡åã«èµ°ããããã¨ãã§ããªãã®ã§ moroããã®RSpecç¨ã®ãã¯ãããã¼ã¹ã« ãã«ããã«ãã function! Rspec () let rails_spec_pat = '\<spec/\(models\|controllers\|views\|helpers\)/.*_spec\.rb$' if expand('%:p') =~ rails_spec_pat exe '!rake spec SPEC="'.expand('%:p').'" RSPECOPTS="-fs -c -l '.line('.').'"' else :!spec -fs -c % endif endfunction au BufRead,BufNewFile *_spec.r
{{#tags}}- {{label}}
{{/tags}}