bdd

Client changes in a TDD/BDD process

I'm coming from a big design background, and just learning TDD/BDD so bear with me if this is a simple question. It seems that many client decisions aren't actually recorded anywhere - they're just documented in the code and tests. So my question is: what happens when the client changes some of these undocumented decisions? How do yo...

Is this a poor design?

I'm trying my hand at behavior driven development and I'm finding myself second guessing my design as I'm writing it. This is my first greenfield project and it may just be my lack of experience. Anyway, here's a simple spec for the class(s) I'm writing. It's written in NUnit in a BDD style instead of using a dedicated behavior driven fr...

Should I change the naming convention for my unit tests?

I currently use a simple convention for my unit tests. If I have a class named "EmployeeReader", I create a test class named "EmployeeReader.Tests. I then create all the tests for the class in the test class with names such as: Reading_Valid_Employee_Data_Correctly_Generates_Employee_Object Reading_Missing_Employee_Data_Throws_Invalid_...

Which BDD framework for Java do you use?

What's the best BDD framework to use with Java? Why? What are the pros and cons of each framework? I've found couple of them here, but I'm not sure which one to choose. Does it make sense to use a BDD framework if I already use a mocking library (e.g. Mockito)? ...

How do you develop outside-in Rails app using Cucumber & RSpec?

I just get started using BDD in Rails application, but I'm not sure what are best practices and workflows? And what other things that I really need for testing for my project such as step definitions, controllers, models, and views? Do I need to test all of those? ...

Cucumber: Automatic step file creation?

When i run cucumber it displays the possible steps that i should define, an example from the RSpec book: 1 scenario (1 undefined) 4 steps (4 undefined) 0m0.001s You can implement step definitions for undefined steps with these snippets: Given /^I am not yet playing$/ do pending end When /^I start a new game$/ do pending end Then /^t...

BDD and MSpec, am I approaching this right?

Hi guys, Just wondering if any MSpec and BDDers out there could give me there thoughts on my first attempt at writing a MSpec spec. Now I've left the specs uncoded, but my context has code in it, I just want to know if I'm heading along the right lines, or if there are any improvements to be made with what I've done. As this can be sub...

Good resource to learn BDD, TDD (ruby , C#, javascript)

What are the good resource to learn BDD & TDD (ruby , C#, javascript). What are the good framework using now? ...

Ngourd C# BDD Cucumber

http://code.google.com/p/ngourd/downloads/list above is the link for NGourd, a C# BDD testing framework. Question is How do i download this? I don't see any link for downloading. I see that under the "Wiki" tab there is a "QuickStart" link and no other link to download. thanks for you help. Please supply with a link in your answer so i ...

how to phrase the result of an action in BDD/TDD

The title is probably not very clear. I have the following example in mind: an Authenticator object authenticates a user using credentials. It returns a AuthResult object. This AuthResult object says the authentication succeeded, or that it failed (and if so, why it failed, eg username not found). How can I phrase this in a test? 'test...

BDD/TDD: can dependencies be a behavior?

I've been told not to use implementation details. A dependency seems like an implementation detail. However I could phrase it also as a behavior. Example: A LinkList depends on a storage engine to store its links (eg LinkStorageInterface). The constructor needs to be passed an instance of an implemented LinkStorageInterface to do its jo...

testing objects using DAO

Continuing another but similar question about testing (see here). I'll use a similare example (pseudocode) class LinkDisplayer method constructor(LinkStorage) method displayLatestLinksByCategory(number_of_them) class LinkStorage method saveLink(Link) method retrieveLatestLinksByCategory(category, number_of_them) class ...

autospec with cucumber in rails app

I have cucumber features working fine and rspec spec working fine i can run both cucumber features and spec spec and they all work but now im looking at getting autospec to run but running does the produces the following Warning: $KCODE is NONE. /opt/local/lib/ruby/gems/1.8/gems/cucumber-0.3.90/lib/cucumber/step_definition.rb:100: warni...

Starting BDD resources?

What would you recommend to start learning and applying BDD on a casual game development studio? ...

BDD in Objective-C

I have recently started to learn Objective-C and write my tests using OCUnit that comes bundled with Xcode. I'm a long time Ruby programmer and I'm used to RSpec and Cucumber - nice BDD frameworks. Is there a decent BDD framework to use in Objective-C? I'm missing my 'should's :) ...

BDD or TDD? Which do you prefer? and why?

I see many developers disagree on which style of test to use while starting a new project. I'd like to know why you choose this particular style over the other. ...

Can I aim for TDD or BDD in my started project?

I have decided to give a try to TDD and BDD on my already started project, encouraged by answers to questions like this: http://stackoverflow.com/questions/294909/should-i-start-using-tdd-on-a-project-that-doesnt-use-it-already I am struggling to really start with it. My project (opensource, hosted in http://gitorious.org/rubots) is gam...

How to integrate Cucumber into Code to Test Ratio?

When I use "rake stats" I can get to know how many lines of code I have written for my RSpec tests. And my RSpec tests influences also the Code to Test Ratio. But can I list my lines of code from the Cucumber steps there, too? Best regards ...

Cucumber for PHP application

Is it possible to use Cucumber outside Rails? I'd like to start using it for testing some of my PHP applications, but I really don't know how to start. Probably the easiest way would be creating a Rails project only to run Cucumber features, but that seems like to me as overkill. What is the simplest way to set up Cucumber for testing ...

Specification Pattern vs Spec in BDD

I'm trying to explore Behavior Driven Design and Domain Driven Design. I'm getting that written specifications drive the tests in BDD, but also that business logic can be encapsulated using the specification pattern for re-use in domain objects and repositories, etc. Are these basically the same concept just used in different ways, use...