mirror of
https://github.com/tiennm99/java-design-patterns.git
synced 2026-05-14 22:58:36 +00:00
title, category, language, tag
| title | category | language | tag | |
|---|---|---|---|---|
| Object Mother | Creational | en |
|
Object Mother
Define a factory of immutable content with separated builder and factory interfaces.
Class diagram
Applicability
Use the Object Mother pattern when
- You want consistent objects over several tests
- You want to reduce code for creation of objects in tests
- Every test should run with fresh data
