rspec 3.1.x in rawhide

Vít Ondruch vondruch at redhat.com
Tue Dec 2 14:24:04 UTC 2014


Dne 2.12.2014 v 13:41 Mamoru TASAKA napsal(a):
> Vít Ondruch wrote on 11/28/2014 08:15 PM:
>> Dne 10.11.2014 v 14:59 Mamoru TASAKA napsal(a):
>>> - Or not, you can use BuildRequires(rspec2). Note that
>>>    2.x version rspec (script) is renamed to %_bindir/rspec2,
>>>    you'll probably have to do
>>>    $ rspec2 spec/
>>>    for example.
>>
>> Used the rspec2 command for the first time, I have strange feeling about
>> it. Shouldn't we provide also plain rspec command for rspec2?
>>
>> Let me explain. When you install RSpec 2.x and RSpec 3.x side by side by
>> gem install, you'll get single rspec executable. You can later choose
>> which version you actually want to execute by something like "rspec
>> _2.2_".
>
> And this won't work at all when rspec2 and rspec (3) is really
> parallel installed:
>
> [tasaka1 at localhost rspec-expectations-2.14.5]$ rspec _2.14.8_ spec
> Run options: include {:focused=>true}
>
> All examples were filtered out; ignoring {:focused=>true}
> FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
> FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
> FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
> FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
> FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
> FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
> (very long, rest cut out)
>
> ... And so current rspec2 "command" won't work either, in
> this way.
> This is because while rspec _2.14.8_ tries to use rspec-core with
> that version, for rspec-expectations and rspec-mocks (used
> internally) this does not apply.

Yes, you are right. It is because the rspec-core does not enforce the
dependencies on rspec-mock and rspec-expectations, hence it can't
enforce their versions ... not nice :/

>
> So the correct way is to specify core, expectations, mocks all
> versions to "~> 2.14.0" in /usr/bin/rspec2
> (fixed in rubygem-rspec2-core-2.14.8-4.fc22), and we don't expect
> that rspec _2.14.8_ really works.
>
>

It is silly that RSpec supports just precise version specification, so
even your fix cannot narrow this issue :/ I opened upstream ticket [1]
which could help to resolve this issue.


Vít


[1] https://github.com/rubygems/rubygems/issues/1088



More information about the ruby-sig mailing list