Category Archive: testing

Feb 02

Keep your Cukes Narrow

It is not uncommon to wonder about how to create data for cukes… Keep it high level? Given I have 4 products Or explicitly define data; e.g., using a table As a broad answer to this question, it all depends on what behavior you are specifying. There is no single, right way. My usual rule …

Continue reading »

Mar 06

Manual Cucumber Tests?

there was some discussion over on the cucumber list about manual testing. cucumber is great at BDD, but it doesn’t mean it is the only test technique (preaching to choir) we should use. i have learned it is critical to understand where automated tests shine, and where human testing is critical — and to not …

Continue reading »

May 11

You Don’t Always Have to Follow “The” Rules

RSpec for an API

A user was asking the following on the Agile Modeling list: What experience does anyone have about standards for stories written for non-UI components? I’m working with a proxy PO who feels the standard story format (As a <user> I want to <activity> so that <purpose>) simply won’t work for something that doesn’t have a …

Continue reading »

Apr 20

Factory Girl and MongoMapper

Factory Folder

You were probably hoping for some Rosey the Riveter poster… Instead, I am going to extend my small MongoMapper example to include Factory Girl. The steps are pretty simple: Go here to install… Create your factories Use the factories in Cucumber/RSpec Factory Construction I created a new “factories” folder under the spec folder: The factories …

Continue reading »

Apr 20

Cucumber, RSpec, MongoMapper, Git, Oh My!

Commit History

Nick left a question on my many-to-many associations post. He wanted to know more about sorting by date and querying… So I decided to (over achieve and) show how I would approach that as if I were adding a new feature: Adding a “date” key field and an index Using Cucumber to drive the new …

Continue reading »

Nov 01

Refactoring Cucumber Features

I was inspired by this post (You’re Cuking It Wrong) to re-look at some feature specs to see if I could improve them. I went from here: Feature: Season Management … Scenario: Create a Season Given an organization like “My YMCA” When I add a season like “Summer Basketball” for “My YMCA” from “1 May” …

Continue reading »