Having trouble getting cucumber 6.3 to run on rails 2.3.4

I am trying to to get cucumber to run with no luck. Here is the error I am seeing:

cucumber features Using the default profile... no such file to

load -- test/ (MissingSourceFile) /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in gem_original_require' /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in polyglot_original_require' /Library/Ruby/Gems/1.8/gems/polyglot-0.3.0/lib/polyglot.rb:65:in require' /Library/Ruby/Gems/1.8/gems/activesupport-2.3.4/lib/active_support/dependencies.rb:158:in require' /Users/yakovrabinovich/Starstreet/starstreet/vendor/gems/cucumber-0.6.3/bin/../lib/cucumber/rails/world.rb:11 /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in gem_original_require' /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in polyglot_original_require' /Library/Ruby/Gems/1.8/gems/polyglot-0.3.0/lib/polyglot.rb:65:in require' /Library/Ruby/Gems/1.8/gems/activesupport-2.3.4/lib/active_support/dependencies.rb:158:in require' /Library/Ruby/Gems/1.8/gems/cucumber-rails-0.3.0/lib/cucumber/rails/rspec.rb:1 /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in gem_original_require' /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in gem_original_require' /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in polyglot_original_require' /Library/Ruby/Gems/1.8/gems/polyglot-0.3.0/lib/polyglot.rb:65:in require' /Library/Ruby/Gems/1.8/gems/activesupport-2.3.4/lib/active_support/dependencies.rb:158:in require' /Users/yakovrabinovich/Starstreet/starstreet/features/support/env.rb:11 /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in gem_original_require' /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in polyglot_original_require' /Library/Ruby/Gems/1.8/gems/polyglot-0.3.0/lib/polyglot.rb:65:in require' /Library/Ruby/Gems/1.8/gems/cucumber-0.6.3/bin/../lib/cucumber/rb_support/rb_language.rb:124:in load_code_file' /Library/Ruby/Gems/1.8/gems/cucumber-0.6.3/bin/../lib/cucumber/step_mother.rb:85:in load_code_file' /Library/Ruby/Gems/1.8/gems/cucumber-0.6.3/bin/../lib/cucumber/step_mother.rb:77:in load_code_files' /Library/Ruby/Gems/1.8/gems/cucumber-0.6.3/bin/../lib/cucumber/step_mother.rb:76:in each' /Library/Ruby/Gems/1.8/gems/cucumber-0.6.3/bin/../lib/cucumber/step_mother.rb:76:in each' /Library/Ruby/Gems/1.8/gems/cucumber-0.6.3/bin/../lib/cucumber/step_mother.rb:76:in load_code_files' /Library/Ruby/Gems/1.8/gems/cucumber-0.6.3/bin/../lib/cucumber/cli/main.rb:48:in execute!' /Library/Ruby/Gems/1.8/gems/cucumber-0.6.3/bin/../lib/cucumber/cli/main.rb:20:in execute!' /Library/Ruby/Gems/1.8/gems/cucumber-0.6.3/bin/../lib/cucumber/cli/main.rb:20:in execute' /Library/Ruby/Gems/1.8/gems/cucumber-0.6.3/bin/cucumber:8 /usr/bin/cucumber:19:in `load' /usr/bin/cucumber:19

Here are my gems:

Yakov-Rabinovichs-MacBook:1.8 yakovrabinovich$ gem list

* LOCAL GEMS *

aasm (2.1.3)
acl9 (0.11.0)
actionmailer (2.3.4, 2.2.2, 1.3.6)
actionpack (2.3.4, 2.2.2, 1.13.6)
actionwebservice (1.2.6)
activerecord (2.3.4, 2.2.2, 1.15.6)
activeresource (2.3.4, 2.2.2)
activesupport (2.3.4, 2.2.2, 1.4.4)
acts_as_ferret (0.4.3)
authlogic (2.1.3)
bgetting-hominid (1.2.0)
builder (2.1.2)
capistrano (2.5.2)
capistrano-ext (1.2.1)
cgi_multipart_eof_fix (2.5.0)
chronic (0.2.3)
columnize (0.3.1)
configatron (2.5.1)
cucumber (0.6.3)
cucumber-rails (0.3.0)
daemons (1.0.10)
database_cleaner (0.5.0)
diff-lcs (1.1.2)
dnssd (0.6.0)
factory_girl (1.2.3)
fastthread (1.0.1)
fcgi (0.8.7)
ferret (0.11.6)
gem_plugin (0.2.3)
gemcutter (0.4.1)
highline (1.5.0)
hoe (2.5.0)
hominid (2.1.0)
hpricot (0.6.164)
json (1.2.0)
json_pure (1.2.0)
libxml-ruby (1.1.2)
linecache (0.43)
mocha (0.9.8)
mongrel (1.1.5)
needle (1.3.0)
net-scp (1.0.1)
net-sftp (2.0.1, 1.1.1)
net-ssh (2.0.16, 2.0.4, 1.1.4)
net-ssh-gateway (1.0.0)
nokogiri (1.4.1)
oauth (0.3.6)
pg (0.8.0)
polyglot (0.3.0)
rack (1.0.1)
rack-test (0.5.3)
rails (2.3.4, 2.2.2, 1.2.6)
rake (0.8.7, 0.8.3)
RedCloth (4.1.1)
rspec (1.3.0)
rspec-rails (1.3.2)
ruby-debug (0.10.3)
ruby-debug-base (0.10.3)
ruby-hmac (0.4.0)
ruby-openid (2.1.2)
ruby-yadis (0.3.4)
rubyforge (2.0.3)
rubygems-update (1.3.5)
rubynode (0.1.5)
sqlite3-ruby (1.2.4)
term-ansicolor (1.0.4)
termios (0.9.4)
test-unit (1.2.3)
thoughtbot-factory_girl (1.2.2)
thoughtbot-shoulda (2.10.2)
treetop (1.4.4)
whenever (0.4.1)
will_paginate (2.3.11)
xmpp4r (0.4)
yamler (0.1.0)

Any help would be greatly appreciated!


Did you run the Cucumber generator after you installed the Cucumber gems? It's all documented here. http://wiki.github.com/aslakhellesoy/cucumber/ruby-on-rails

I seem to remember getting that error when i forgot to run the generator on my own install. The 'default profile' your error mentions is referred to in the cucumber.yml file thats created on running the generator.

ruby script/generate cucumber


Try setting the environment variable RSPEC, it looks like it's looking in your test/unit directories (assuming you're using rspec of course!)

export RSPEC=true

It might also be the default setting in config/cucumber.yaml is looking for a file that isn't there. Rename this file temporarily and see if it starts working. I had to remove a lot of cruft from mine. For reference, it looks like this:

<%
# rerun = File.file?('rerun.txt') ? IO.read('rerun.txt') : ""
# rerun_opts = rerun.to_s.strip.empty? ? "--format progress features" : "--format           #{ENV['CUCUMBER_FORMAT'] || 'pretty'} #{rerun}"
# std_opts = "#{rerun_opts} --format rerun --out rerun.txt --strict --tags ~@wip"
std_opts = "--format progress features"
%>
default: <%= std_opts %>
wip: --tags @wip:3 --wip features

As you can see I commented a lot of it out.

链接地址: http://www.djcxy.com/p/6602.html

上一篇: 在不同的浏览器中使用黄瓜/水豚/硒有问题

下一篇: 无法让黄瓜6.3在rails上运行2.3.4