[rspec-users] Cucumber: Running one feature under one profile
aslak.hellesoy at gmail.com
Fri May 22 18:02:52 EDT 2009
> aslak hellesoy wrote:
>>> Hey Folks,
>> Aargh profiles. The initial intention was that you could just do
>> cucumber -p foo.
>> And then you wouldn't have to type a lot of arguments.
>> The intention was *not* to use -p along with additional arguments,
>> although cucumber lets you do it by merging stuff together.
>> Using profiles as a mechanism to run various subsets of features and
>> step definitions that live underneath the same features directory is
>> something I do *not* recommend. It's much easier to have several
>> different root folders:
>> features # regular stuff
>> selenium_features # only selenium stuff
>> And a rake task for each. Or run cucumber selenium_features or
>> cucumber features as you see fit.
>> I know the wiki recommends all this crazy profile stuff. I'm sorry
>> about that - I didn't write it.
> I somewhat disagree, the combination of profiles + tags is a good way to
> organize the features IMO.
> The feature file talks about the feature
> regardless of if it uses JS or not. So, if you have a feature that uses
> webrat 90% of the time but then has one or two scenarios that require JS you
> don't need to split that feature into two separate features files- you can
> just tag them. I can see how having separate dirs can be helpful as well,
> but in general I kinda like the "crazy profile" stuff. :)
Good points Ben.
People ask questions almost daily about Selenium, and many of them
seem related to profiles. Since I don't use either of them much I'm
not in a good position to help people with it. That's why I recommend
people go for a less complex setup.
>>> I followed the instructions on
>>> and created 2 profiles: default and selenium. It works, but not if I
>>> want to run one feature under a specifc profile. For example, I tried:
>>> cucumber -p default --require features features/plain/
>>> and I get all the tests including the selenium server.
>>> What's goin' on like?
>> Try to add --verbose to see what's going on. Or better - organise your
>> features like I described above, and lose the profiles.
>>> rspec-users mailing list
>>> rspec-users at rubyforge.org
>> rspec-users mailing list
>> rspec-users at rubyforge.org
> rspec-users mailing list
> rspec-users at rubyforge.org
More information about the rspec-users