Skip to content

Conversation

@xlegalles
Copy link
Contributor

Dependency injection is supported in Workflow but cannot be tested (fix)
It is related to changes made in PR: Allow dependency injection on Workflow #576
The new() constraint on TWokflow is still present on WorkflowTest while it has been removed elsewhere

Dependency injection is supported in Workflow but cannot be tested (fix)
fix: moved DI regstration
@xlegalles
Copy link
Contributor Author

It may also be useful to add comments in the documentation:

  • "step and workflow classes must be registered in the DI container if they expect dependencies to be injected". This is obvious, but personally I was expecting that it was already done by default.
  • "step classes must inherit directly from StepBody/StepBodyAsync i.e. cannot inherit from intermediate classes". No factorization allowed as I've started to do.

Thank you

@daniele-betsson
Copy link

would be fantastic to have this merged some years later :D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants