wood burning stoves
The moose likes Agile and Other Processes and the fly likes BDD versus TDD Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Agile and Other Processes
Bookmark "BDD versus TDD" Watch "BDD versus TDD" New topic

BDD versus TDD

Zhia-zhia Xiu Bai

Joined: Aug 29, 2007
Posts: 13
I have worked on a team that uses TDD(test driven development) and XP(extreme programming) with continuous integration of code just as outlined by Martin Fowler.(cvs, CruiseControl, daily commits, Junit, automated build scripts).
I am looking to broaden my skills as a developer and have started to teach myself Ruby(on Rails as well) and BDD(behavioral driven development).
What are your thoughts, if any, about BDD versus TDD?
Adeel Ansari
Ranch Hand

Joined: Aug 15, 2004
Posts: 2874
I don't believe we have a "Versus" kind of thing between BDD and TDD. We can use both, why not? BDD is a common sense approach. I have been following it since long without even knowing this word, 'BBD'. On the contrary, I consider TDD as an idea, which was not there - or better say not common and still not common. It is kind of approach not everybody was familiar with. You can say BDD emphasize on one point - as it names suggest - and TDD on the other. But it doesn't mean that there is no tests and no behavioral approach in BDD and TDD, respectively. Its just the name. May be few folks misunderstood the term BDD, as we can know from wikipedia's definition of the term BDD. In fact BDD is kind of integration between TDD and DDD.

A good resource for BDD.
Paul Duvall

Joined: Jul 17, 2007
Posts: 29
What are your thoughts, if any, about BDD versus TDD?

I think Andy will be replying to this later, but for now, have a look at his blog article on the topic here: http://thediscoblog.com/2007/08/28/is-bdd-tdd-done-right/

Co-author of <a href="http://www.amazon.com/gp/product/0321336380/" target="_blank" rel="nofollow">Continuous Integration: Improving Software Quality and Reducing Risk </a> <br />(Addison-Wesley Martin Fowler Signature Series, 2007). Companion website for the book is <a href="http://www.integratebutton.com/" target="_blank" rel="nofollow">IntegrateButton.com</a>
Ilja Preuss

Joined: Jul 11, 2001
Posts: 14112
I also don't see any "versus" between TDD and BDD.

What I very much like about BDD is the focus on, well, describing behavior. I simply like tests that read very much like a natural description of the expected behavior of a class.

What I'm not convinced of is the focus on using mocks that seems to be connected to BDD. It is my experience that often state based testing seems to be simpler and more stable than interaction based testing.

The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
I agree. Here's the link: http://aspose.com/file-tools
subject: BDD versus TDD
It's not a secret anymore!