Cucumber.js with PhantomJS
A quick example showing how to use Cucumber.js with PhantomJS.
Install
brew install phantomjs
- install phantomjsnpm install -g grunt-cli
- install grunt command line toolsnpm install
- install dependenciesphantomjs --webdriver=4444
- start phantom- in another terminal window use
grunt
to run tests
Links
- Cucumber Feature Syntax
- Feature Introduction
- Scenario-Outlines
- Backgrounds
- Given/When/Then Syntax
- WebDriver API
Notes
This is using a fork of cucumber that adds colorized output.
http://behrang.github.io/presentations/cucumber/2013-03-12/ was extremely helpful.
Todo
Figure out how to not have to start Phantom manually before running tests.