There's a Tarantula in my Story!

February 27th, 2008

Relevance announced Tarantula this evening. The description says "It crawls your Rails application, fuzzing data to see what breaks." I thought that sounds fun, so off to grab it...

The instructions tell me to "Create a Rails integration test." I haven't done that in quite a while, having sipped the RSpec Kool-aid. I wonder if it will work with the Story Framework?

Well, almost.

I had to make a couple small changes to rails_integration_proxy.rb
Line 30:
status = integration_test.send(verb, url, *args)
Line 32:
patch_response(url, response, status)
Line 38:
if response.code == '404' || (status == 500 && File.exist?(static_content_path(url)))
Everything else seemed to work!

Story: Tarantula

Scenario: Fuzz my data
  Given a logged in fanboy 'Peter_Parker' with password 'AuntMay'
  Then Tarantula should 'bite me'
require File.dirname(__FILE__) + '/../../spec/spec_helper'
require 'relevance/tarantula'

steps_for(:tarantula) do
  Given("a logged in fanboy '$login' with password '$password'") do |login, password|
    post_via_redirect '/login', :login => login, :password => password
  end
  
  Then("Tarantula should 'bite me'") do
    tarantula_crawl(self)
  end
end

1 Response to “There's a Tarantula in my Story!”

  1. Kamal Fariz Says:
    Thanks for the tip. Don't forget Line 37: def patch_response(url, response, status)

Sorry, comments are closed for this article.

Manifesto for Agile Software Development




We are uncovering better ways of developing
software by doing it and helping others do it.
Through this work we have come to value:

Individuals and interactions over processes and tools
Working software over comprehensive documentation
Customer collaboration over contract negotiation
Responding to change over following a plan

That is, while there is value in the items on
the right, we value the items on the left more.




Kent Beck
Mike Beedle
Arie van Bennekum
Alistair Cockburn
Ward Cunningham
Martin Fowler
James Grenning
Jim Highsmith
Andrew Hunt
Ron Jeffries
Jon Kern
Brian Marick
Robert C. Martin
Steve Mellor
Ken Schwaber
Jeff Sutherland
Dave Thomas



© 2001, the above authors
this declaration may be freely copied in any form,
but only in its entirety through this notice.