Skip to content

Commit

Permalink
trying to merge in master
Browse files Browse the repository at this point in the history
  • Loading branch information
vantreeseba committed Feb 5, 2014
2 parents 1967b21 + b5bd31a commit b013d39
Show file tree
Hide file tree
Showing 103 changed files with 18,490 additions and 3,155 deletions.
21 changes: 15 additions & 6 deletions .travis.yml
@@ -1,14 +1,23 @@
rvm: "1.9.2"
before_script: "git submodule update --init && npm install"
before_install:
- ruby --version
- gem --version
- rvm --version
- bundle install

script: "rake"

language: node_js

node_js:
- 0.4
- 0.6
- "0.11"
- "0.10"
- "0.8"
- "0.6"

branches:
only:
- master
matrix:
allow_failures:
- node_js: "0.11"

notifications:
email:
Expand Down
115 changes: 115 additions & 0 deletions CONTRIBUTE.md
@@ -0,0 +1,115 @@
## Thank you!

Before anything else, thank you. Thank you for taking some of your precious time helping this project move forward.

This guide will help you get started with Cucumber.js's development environment. You'll also find the set of rules you're expected to follow in order to submit improvements and fixes to Cucumber.js.

## Get started

After forking and cloning the repository, install the required dependencies:

$ cd <path/to/cucumber-js>
$ npm link

## Play

$ node example/server.js

Then go to [localhost:9797](http://localhost:9797/) to see the little web demo.

## Tests

There are two set of tests resulting from the BDD approach we've been applying to Cucumber.js from the beginning.

* full-stack tests (outside): surprisingly those are Gherkin scenarios;
* unit tests (inside): jasmine specs.

### Specs

Run the specs:

$ node_modules/.bin/jasmine-node spec

### Features & documentation

There is a common set of features shared by all cucumber implementations. It's called the *Technology Compatibility Kit* or *TCK*. Find more on the [Cucumber TCK](http://github.com/cucumber/cucumber-tck) repository.

The official way of running them is through Cucumber-ruby and Aruba. Ruby and Bundler are required for this to work.

$ git submodule update --init
$ bundle
$ rm -rf doc; ARUBA_REPORT_DIR=doc cucumber features/cucumber-tck -r features

*Note*: you need the *bcat* and *rdiscount* gems in order to use the `ARUBA_REPORT_DIR` environment variable. Install it with `gem install bcat rdiscount`.

You can then open the generated documentation:

$ open doc/features/cucumber-tck/*.html # might open a lot of files ;)

In addition to that, Cucumber.js is able to run the features for itself too:

$ ./bin/cucumber.js features/cucumber-tck -r features

There are a few other Cucumber.js-dependent features. Execute everything:

$ ./bin/cucumber.js

### Rake

Alternatively, you can run everything with the help of Rake:

$ git submodule update --init
$ bundle
$ rake

### Debug messages

You can display debug messages by setting the DEBUG_LEVEL environment variable. It goes from `1` to `5`. `5` will display everything, `1` will only print out the critical things.

$ DEBUG_LEVEL=5 ./bin/cucumber.js

It even works with Aruba:

$ rm -rf doc; DEBUG_LEVEL=5 ARUBA_REPORT_DIR=doc cucumber features/cucumber-tck -r features
$ open doc/features/cucumber-tck/*.html # you'll see debug messages in Aruba-generated docs


## Coding guidelines

If you plan on submitting code, read this carefully. Please note it is not yet complete.

We stick to the [Google JavaScript Style Guide](http://google-styleguide.googlecode.com/svn/trunk/javascriptguide.xml).

In addition to those syntactic rules, we apply the following principles:

### Write expressive method and function names

Use expressive names. Express arguments as part of the method/function name. Someone calling it should be able to infer the expected arguments only from the name. They shouldn't have to check the method/function definition.

``` javascript
adorn(/* ... */) // BAD: it does not tell anything about its
// parameters, you'll need to read the method
// definition to know the arguments.

addStyleToText(/* ... */) // you can fairly guess this function
// accepts "style" and "text" arguments:
```

** WORK IN PROGRESS **

## Release checklist

This a reminder of the steps maintainers have to follow to release a new version of Cucumber.js.

* Update development status in `README.md`, if relevant
* Update `History.md`
* Bump version in `lib/cucumber.js`
* Bump version in `package.json`
* Bump version in `bower.json`
* Compile the bundle with `node scripts/compile-release.js`
* Add new contributors to `package.json`, if any
* Commit those changes as "*Release 0.1.2*" (where *0.1.2* is the actual version, of course)
* Tag commit as "v0.1.2" with short description of main changes
* Push to main repo on GitHub
* Wait for build to go green
* Publish to NPM
2 changes: 1 addition & 1 deletion Gemfile
@@ -1,7 +1,7 @@
source :rubygems

group :test do
gem "aruba", "0.4.7"
gem "aruba", "0.4.11"
end

group :dev do
Expand Down
52 changes: 26 additions & 26 deletions Gemfile.lock
@@ -1,43 +1,43 @@
GEM
remote: http://rubygems.org/
specs:
aruba (0.4.7)
childprocess (>= 0.2.2)
aruba (0.4.11)
childprocess (>= 0.2.3)
cucumber (>= 1.1.1)
ffi (= 1.0.9)
ffi (>= 1.0.11)
rspec (>= 2.7.0)
builder (3.0.0)
childprocess (0.2.3)
ffi (~> 1.0.6)
cucumber (1.1.3)
builder (3.1.3)
childprocess (0.3.5)
ffi (~> 1.0, >= 1.0.6)
cucumber (1.2.1)
builder (>= 2.1.2)
diff-lcs (>= 1.1.2)
gherkin (~> 2.6.7)
diff-lcs (>= 1.1.3)
gherkin (~> 2.11.0)
json (>= 1.4.6)
term-ansicolor (>= 1.0.6)
diff-lcs (1.1.3)
ffi (1.0.9)
gherkin (2.6.8)
ffi (1.1.5)
gherkin (2.11.3)
json (>= 1.4.6)
guard (0.8.2)
thor (~> 0.14.6)
guard (1.4.0)
listen (>= 0.4.2)
thor (>= 0.14.6)
guard-jasmine-node (0.0.5)
guard (>= 0.4)
json (1.6.3)
rspec (2.7.0)
rspec-core (~> 2.7.0)
rspec-expectations (~> 2.7.0)
rspec-mocks (~> 2.7.0)
rspec-core (2.7.1)
rspec-expectations (2.7.0)
diff-lcs (~> 1.1.2)
rspec-mocks (2.7.0)
term-ansicolor (1.0.7)
thor (0.14.6)
json (1.7.5)
listen (0.5.3)
rspec (2.11.0)
rspec-core (~> 2.11.0)
rspec-expectations (~> 2.11.0)
rspec-mocks (~> 2.11.0)
rspec-core (2.11.1)
rspec-expectations (2.11.3)
diff-lcs (~> 1.1.3)
rspec-mocks (2.11.3)
thor (0.16.0)

PLATFORMS
ruby

DEPENDENCIES
aruba (= 0.4.7)
aruba (= 0.4.11)
guard-jasmine-node (= 0.0.5)

0 comments on commit b013d39

Please sign in to comment.