开发者

How to run an entire rspec group from the command line?

开发者 https://www.devze.com 2023-01-10 06:22 出处:网络
I can run a single rspec example with spec -e \'should be awesome\' spec/models/stuff_spec.rb but how do I run an e开发者_开发知识库ntire group ?

I can run a single rspec example with

spec -e 'should be awesome' spec/models/stuff_spec.rb

but how do I run an e开发者_开发知识库ntire group ?

describe 'GoodStuff' do
  it 'should be awesome' do
    true.should be_true
  end
  it 'want to run this too' do
    true.should be_true
  end
end

I've heard there's a spec -g option, but a) its not documented b) it does not work for me on rspec 1.3.0..


spec -l N # thats minus L where the line number is that of the describe group..

PPS - I've heard of spec -g 'GoodStuff' - but that doesn't work for me on rspec 1.3.0

0

精彩评论

暂无评论...
验证码 换一张
取 消