BDD or TDD? Which one do you prefer? and why?
TDD v BDD is truly a state of mind. The way I see it, TDD places a lot of emphasis on what should be in that value at this stage, where I see BDD that will also check the values ββand how we got them, how more when it is in this state, what is this part of my application supposed to do.
source to share
I usually use the out principle . If you name that TDD or BDD is less important to me.
This means that I start with the most significant part of the function that I want to implement and work from there. This is often the user interface, but it is not required. Sometimes the most important area is a maintenance operation or a background process, and then I start there.
I use Test Doubles to determine how the classes I define interact with its environment, and then implement more and more of the abstractions defined by those double tests as I implement this feature.
So, I think you could say that I start thinking in BDD style and then move more and more towards TDD as I, for example, work my way up to the call table.
source to share