A provider that substitutes bindings in the container.
Overriding through a provider rather than through a back door means the substitution happens where
every other registration happens, in the container the kernel builds for each event. A fake stays
a fake for the whole dispatch, and the code under test resolves it exactly as it resolves the real
one: nothing in the application knows it is being tested.
Registered after the application's own providers, so the fake wins over what it replaces. It binds
unconditionally for the same reason: substituting is the entire point.
A provider that substitutes bindings in the container.
Overriding through a provider rather than through a back door means the substitution happens where every other registration happens, in the container the kernel builds for each event. A fake stays a fake for the whole dispatch, and the code under test resolves it exactly as it resolves the real one: nothing in the application knows it is being tested.
Registered after the application's own providers, so the fake wins over what it replaces. It binds unconditionally for the same reason: substituting is the entire point.