Permalink
Browse files

Updated example with exact gem versions

  • Loading branch information...
1 parent 22cd882 commit b770e13d4acdcf315b014e68747061e2d8c0edef @cayblood committed Jul 9, 2010
Showing with 42 additions and 5 deletions.
  1. +27 −0 README
  2. +14 −4 Rakefile
  3. +1 −1 cucumber.yml
View
27 README
@@ -1,3 +1,30 @@
+INSTALLATION
+
+1) gem install rvm
+2) follow the instructions for setting up rvm
+3) rvm install 1.8.7
+4) rvm use 1.8.7
+5) rvm gemset create cucumber-webrat-mechanize-example
+6) rvm gemset use cucumber-webrat-mechanize-example
+7) run the following commands:
+
+gem install term-ansicolor -v 1.0.4
+gem install polyglot -v 0.3.1
+gem install treetop -v 1.4.1
+gem install diff-lcs -v 1.1.2
+gem install builder -v 2.1.2
+gem install cucumber -v 0.3.99
+gem install nokogiri -v 1.3.3
+gem install rack -v 1.0.0
+gem install webrat -v 0.5.3
+gem install mechanize -v 0.9.3
+gem install json_pure -v 1.1.9
+gem install rubyforge -v 1.0.4
+gem install hoe -v 2.3.1
+gem install rspec -v 1.2.8
+
+8) You should now be able to execute the example by typing rake
+
For more information, please look at this blog post:
http://surgeworks.com/blog/general/using-cucumber-and-webrat-for-remote-web-testing
View
@@ -1,8 +1,18 @@
$:.unshift(File.dirname(__FILE__) + '/../../lib')
-require 'cucumber/rake/task'
+require 'rubygems'
+
+begin
+ require 'cucumber'
+ require 'cucumber/rake/task'
-Cucumber::Rake::Task.new do |t|
- t.cucumber_opts = %w{--format pretty}
+ Cucumber::Rake::Task.new do |t|
+ t.cucumber_opts = %w{--format pretty}
+ end
+rescue LoadError
+ desc 'Cucumber rake task not available'
+ task :cucumber do
+ abort 'Cucumber rake task is not available. Be sure to install cucumber as a gem or plugin'
+ end
end
-task :default => :features
+task :default => :cucumber
View
@@ -1 +1 @@
-default: -r features/support/env.rb -r features/step_definitions features
+default: -r features/support/env.rb -r features/step_definitions features

3 comments on commit b770e13

Contributor

aslakhellesoy commented on b770e13 Jul 20, 2010

Hi Carl,

Why are you using such an old version of Cucumber? We're at 0.8.5 now :-)

Owner

cayblood replied Jul 20, 2010

Just wanted to pin to the versions that were working when I wrote this. Current versions gave a webrat error. Didn't have time to debug it at that the time :-(

Owner

cayblood replied Jul 29, 2010

OK, I've merged in your changes and fixed the feature so it works. Thanks for bringing me up to speed :-)

Please sign in to comment.