When a new team spins up at Pivotal time is set aside to get everyone onboard with the basic principles of XP, SOLID and TDD.
Today we walked through dependency inversion. Here are my notes.
- Modeling Exercises
- TDD Exercise
Dependency Injection. Dependency Inversion. How are they related?
- Compile time dependencies vs runtime flow of control.
- High level policy should be independent of low level detail.
- Concretions should depend on abstractions.
- Depend in the direction of stability.
Injection allows you to provide dependencies to something else.
First working example. 1978. Using the Z 80 Assembler language. In a phone system. One release of their software. A new company. In memory reallocation.
- More readable code.
- More freedom at the time of build.
- Open to expansion. Closed to modification.
- programming by wishful thinking.
Types of test doubles
- Does it make sense to shift the contract with only once device?
- Naming contracts based on behaviour is scary.