Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 64 lines (35 sloc) 2.133 kB
ea033b2 @aslakhellesoy Remove support for Rails2
aslakhellesoy authored
1 # Cucumber-Rails
2
ddfb7eb @aslakhellesoy Point travis staus to our own
aslakhellesoy authored
3 [![Build Status](https://secure.travis-ci.org/cucumber/cucumber-rails.png)](http://travis-ci.org/cucumber/cucumber-rails)
f949d91 @chaffeqa added travis-ci integration and image in README
chaffeqa authored
4
cf6b2eb @aslakhellesoy Added a note about Rails 2.x support, linking to the old instructions…
aslakhellesoy authored
5 Cucumber-Rails brings Cucumber to Rails 3.x. For Rails 2x support, see the [Cucumber Wiki](https://github.com/cucumber/cucumber/wiki/Ruby-on-Rails).
6
ea033b2 @aslakhellesoy Remove support for Rails2
aslakhellesoy authored
7 ## Installation
8
9 Before you can use the generator, add the gem to your project's Gemfile as follows:
10
11 group :test do
0a8c86e @rdlugosz Fix #202 - warning msg should include require: false
rdlugosz authored
12 gem 'cucumber-rails', :require => false
ea033b2 @aslakhellesoy Remove support for Rails2
aslakhellesoy authored
13 # database_cleaner is not required, but highly recommended
14 gem 'database_cleaner'
15 end
16
17 Then install it by running:
18
19 bundle install
20
21 Learn about the various options:
22
6f4ae14 @albertoleal Fixed some commands on README.md file.
albertoleal authored
23 rails generate cucumber:install --help
ea033b2 @aslakhellesoy Remove support for Rails2
aslakhellesoy authored
24
25 Finally, bootstrap your Rails app, for example:
26
27 rails generate cucumber:install
28
29 ## Running Cucumber
30
31 With Rake:
32
33 rake cucumber
34
35 Without Rake:
36
37 [bundle exec] cucumber
38
708d296 @aslakhellesoy Edited README.md via GitHub
aslakhellesoy authored
39 ## Bugs and feature requests
ea033b2 @aslakhellesoy Remove support for Rails2
aslakhellesoy authored
40
2e3161a @aslakhellesoy Edited README.md via GitHub
aslakhellesoy authored
41 The *only* way to have a bug fixed or a new feature accepted is to describe it with a Cucumber feature. Let's say you think you have found a bug in the cucumber:install generator. Fork this project, clone it to your workstation and check out a branch with a descriptive name:
ea033b2 @aslakhellesoy Remove support for Rails2
aslakhellesoy authored
42
708d296 @aslakhellesoy Edited README.md via GitHub
aslakhellesoy authored
43 git clone git@github.com:you/cucumber-rails.git
44 git checkout -b bug-install-generator
ea033b2 @aslakhellesoy Remove support for Rails2
aslakhellesoy authored
45
708d296 @aslakhellesoy Edited README.md via GitHub
aslakhellesoy authored
46 Start by making sure you can run the existing features. Now, create a feature that demonstrates what's wrong. See the existing features for examples. When you have a failing feature that reproduces the bug, commit, push and send a pull request. Someone from the Cucumber-Rails team will review it and hopefully create a fix.
47
48 If you know how to fix the bug yourself, make a second commit (after committing the failing feature) before you send the pull request.
ea033b2 @aslakhellesoy Remove support for Rails2
aslakhellesoy authored
49
50 ### Setting up your environment
51
6167d94 @aslakhellesoy recommend ruby 1.9.3
aslakhellesoy authored
52 I strongly recommend rvm and ruby 1.9.3. When you have that, cd into your cucumber-rails repository and:
ea033b2 @aslakhellesoy Remove support for Rails2
aslakhellesoy authored
53
b33eadf @aslakhellesoy Edited README.md via GitHub
aslakhellesoy authored
54 gem install bundler
55 bundle install
ea033b2 @aslakhellesoy Remove support for Rails2
aslakhellesoy authored
56
57 ### Running all features
58
b33eadf @aslakhellesoy Edited README.md via GitHub
aslakhellesoy authored
59 With all dependencies installed, all features should pass:
60
61 rake cucumber
ea033b2 @aslakhellesoy Remove support for Rails2
aslakhellesoy authored
62
63 One of the features uses MongoDB, which needs to be running in order to make features/mongoid.feature to pass.
Something went wrong with that request. Please try again.