views:

1186

answers:

3
Q: 

DDD vs TDD

Which one offers more advantages for a large software, say like Photoshop?

Also by TDD I don't mean just unit tests, because you can use unit tests in DDD too, just not the same way TDD does.

DDD: Design-Driven Development

TDD: Test-Driven Development

+5  A: 

I also don't think they're mutually exclusive I think you can use TDD to get to DDD.

+16  A: 

DDD = Domain Driven Design

TDD means that before you write any unit of behavior you have a test for this behavior and only this behavior. Only after these tests fail do you implement the behavior. In every incarnation that I've seen TDD has been on the level of a method or class - maybe a couple classes working together. The end result is that you get highly testable and hence very loosely coupled code. Ultimately though TDD is about creating code that can be tested.

DDD is a far more abstract philosophy and set of design patterns that addresses how to design a large, scalable, and maintainable system. Ultimately DDD is about creating a code eco-system that implicitly or explicitly captures important bits of domain knowledge.

So you see, they are certainly not mutually exclusive. Pretty much everyone I know who is knowledgeable in DDD is also a hard-core TDD enthusiast.

George Mauer
Downvote? Seriously? WTF?
George Mauer
I thought your answer was very good. Upvote.
awhite
A: 

I still have a question about this...

isn't DDD essentially 'top down' you design and refine a model based on domain knowledge/experience.

whereas TDD is 'bottom up' program design is influenced by the refactoring process and encouraging de-coupling to enhance testabilit.

aren't these two at odd's with each other..?

i.e.whatever model you design will be modified by ur TDD, and anything evolved through TDD may not be harmonis with a well designed domain model?

jay