[Core feature] Support patching subworkflows in unit tests #5312
Labels
enhancement
New feature or request
good first issue
Good for newcomers
help wanted
Extra attention is needed
Motivation: Why do you think this is important?
Currently, flytekit.testing supports patching tasks in workflows, which allows us to unit test that the sequence of workflow tasks is called as expected. This is helpful for task-only workflows, but for more complex workflows that contain subworkflows, we lack the ability to patch the subworkflows and test that they are similarly called in sequence as expected (without needing to know about the internals of the subworkflows themselves).
These tests would help confirm that workflow sequences fire as expected, and protect against unwanted changes to the execution flow in the codebase.
Goal: What should the final outcome look like, ideally?
Ideally, it would be handy having a test decorator that can be used similarly to the task patching decorator already provided within
flytekit.testing
:Describe alternatives you've considered
Without the ability to patch subworkflows, we would need to write unit tests that have knowledge of each workflow in the chain until we reach the task level for patching - this is doable, but breaks the rules of test isolation.
Propose: Link/Inline OR Additional context
No response
Are you sure this issue hasn't been raised already?
Have you read the Code of Conduct?
The text was updated successfully, but these errors were encountered: