Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

Driving Design through Examples

PHP UK Conference via YouTube

Overview

Save Big on Coursera Plus. 7,000+ courses at $160 off. Limited Time Only!
Explore Modelling by Example techniques in this PHP UK Conference talk, combining Behaviour Driven Development (BDD) and Domain Driven Design (DDD) to create a workflow that directly drives code from user requirements. Learn how to define features through stakeholder conversations, capture automatable requirements, and express them in the object model using tools like Behat and PhpSpec. Discover the benefits of using examples to illustrate behavior, understand the Gherkin language for formalizing examples, and grasp the importance of establishing a Ubiquitous Language for effective communication between business and development teams. Gain insights on improving scenarios, modeling values as Value Objects, and defining boundaries with Interfaces to create a more robust and domain-focused codebase.

Syllabus

Intro
Modelling by Example Combining BDD and DDD concepts
Behaviour Driven Development
BDD is the art of using examples in conversations to illustrate behaviour - Liz Keogh
Why Examples?
Rules are Ambiguous
Examples are Unambiguous
Examples are Objectively Testable
Gherkin A formal language for examples
You do not have to use Gherkin
Scenarios are not Contracts
Scenarios Create a shared understanding of a feature + Give a starting definition of done → Provide an objective indication of how to test a feature
Domain Driven Design
DDD tackles complexity by focusing the team's attention on knowledge of the domain - Eric Evans
Ubiquitous Language A shared way of speaking about domain concepts → Reduces the cost of translation when business and development communicate → Try to establish and use terms the business will understand
By embedding Ubiquitous Language in your scenarios, your scenarios naturally become your domain model - Konstantin Kudryashov (@everzet)
The best way to understand the domain is by discussing examples → Write scenarios that capture ubiquitous language → Write scenarios that illustrate real situations Directly drive the code model from those examples
Directly driving code with Behat?
Improving scenarios
Add realistic details
Actively seek terms from the domain
Get good at listening
Model values as Value Objects
Model boundaries with Interfaces

Taught by

PHP UK Conference

Reviews

Start your review of Driving Design through Examples

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.