Documentation request: Context injection with exchanged DI container
Product:
- [x] SpecFlow
- [ ] SpecFlow+ Runner
- [ ] SpecFlow+ LivingDoc
- [ ] SpecMap
What is missing:
I setup Autofac as the DI framework/container of choice like this:
https://docs.specflow.org/projects/specflow/en/latest/Integrations/Autofac.html?highlight=autofac#a-typical-dependency-builder-method-probably-looks-like-this
Using context injection does not to resolve "custom" contexts by default now and these need to be registered in the DI container. Can somebody confirm this?
Would it be a good idea to add this detail to the documentation?
And if really every context needs to be registered, does somebody have an opinion about best practices on a reflection based approach? What do you prefer? Naming convention (*SpecFlowContext)? Custom attribute on context classes? Shared base class?
Just want to have this confirmed by somebody else, after that I would be happy to extend the documentation myself.