LetsTalkCode.com
Programmers talking about code

BDD - From the beginning

May 3, 2008 05:24 by rtennys

I've really been wanting to get deeper into BDD, but I'm having trouble getting the opportunity at work. I think it's a combination of two primary problems (I'm sure there are others as well though). First, it has been freaking ages since I've been present at the very beginning of a project. It seems like I'm always pulled in well after development has started which means well after project style and architecture have been established. Second, my company still hasn't made the shift to Agile practices. The word is starting to be tossed around quite a bit, but we're still primarily a big up front design kind of shop. This is affecting my ability to do BDD because of the first problem - if I'm not there in the beginning to sway the way things are done, then you can bet that by the time I'm there a ton of analysis will have been done and I'll have a pile of functional specs waiting for me.

Now then, I do, despite all of this, do my best to take the functional specs that I'm given and turn them into well formed behavior driven style unit tests.  The problem is that I'm still very new to it and completely suck. On top of that, I'm expected to teach others at the same time (yes, the blind leading the blind). So I need practice. That's where this post comes in. I thought I'd come up with a bunch of quick and easy side projects where I could experience the entire development life cycle. It didn't take very long at all to get stuck trying to figure out what the next step would be if this were a real project at work. I could of course dig in and just get it done, but I'm much more interested in the process than I am the product at this point (otherwise I would have written these apps years ago!). Enough chatter though, on with something interesting...

Powerball Management

This is the first app that I could think of. I've played the same lotto numbers for years and still after all this time go out and check manually every drawing. So, I thought I'd automate that. Below are the requirements that I could think of written in the "As a, I want, So that" style.

Now this is where I'm stuck. This doesn't seem to me enough information to get started, but acting as the end user, I can't think of anything else I want to say about it.

The initial requirements:

  • As a player
    I want to be notified of whether or not I've won after every drawing 
    So that I don't have to check manually
  • As a player
    I want to know how much I've won if I did win
    So that I'm not curious and have to go check manually
  • As a player
    I want to be notified when I need a new ticket
    So that I don't have to remember
  • As a player
    I don't want to have to re-type numbers on new tickets if they're the same
    So that I can save time

I'm going to elicit a bit of help on this and will definitely do a fair bit of reading. I'll post my progress and a link to where I end up putting the code.

Happy coding!


Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5
Tags:
Categories:
Actions: E-mail | Permalink | Comments (1) | Comment RSSRSS comment feed