Decouple

Dependency Breakers

Work around the dependencies with mocks, fakes, or stubs.

Purpose

You can employ the strategy of working around dependencies using mocks, fakes, or stubs. A stub is a placeholder implementation simulating functionality with default values. A fake is a functional but simplified implementation that mimics the more complex behavior of an actual component. A mock is a simulated object replicating behavior, which helps test and validate interactions with the dependent component. With any of these techniques, you can unblock yourself and keep development moving forward.

Notes

Dependencies are not necessarily bad. Actually, there are many good reasons for people to depend on each other. But you have a problem when those dependencies result in value that is not able to flow.

Rules / Constraints

  • We have not yet defined any rules or constraints.

“We have broken the cycle of dependency. People have found out they're better off working.”

(Source: John Engler)