Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/sandro/culerity_fakeweb

Example rails app using fakeweb to return known responses in culerity
https://github.com/sandro/culerity_fakeweb

Last synced: 12 days ago
JSON representation

Example rails app using fakeweb to return known responses in culerity

Awesome Lists containing this project

README

        

h1. Culerity with fakeweb

h2. Florida is fucking cold?

p. This example app uses fakeweb to return an erroneous weather
report for Jacksonville, FL. The cucumber feature called "weather"
asserts that Jacksonville, FL is "fucking cold," which we all
know is rarely true. When the test runs, fakeweb intercepts the
request for Jacksonville weather and instead returns the New York
weather report, which is unfailingly "fucking cold."

h3. Instructions

# sudo script/server -p 80 -e cucumber
# cucumber features/weather.feature
# The test passes!
# read the code

h3. Make it fail

# edit config/environments/cucumber.rb
# comment out the fakeweb uri registration
# restart the server (see above)
# cucumber features/weather.feature
# test fails