Are there any examples of running local unit tests to verify your tasks are working? I'd like to have some pre-deployment checks in my GitHub actions.
a
Anna Geller
01/26/2022, 12:25 PM
So far we have:
• this page about unit-testing flows and tasks
• this discussion about CI/CD in Prefect with several examples from other users
b
Ben Welsh
01/26/2022, 1:07 PM
Thank you. I've got my first flow reading in to my test with
extract_flow_from_file
but I'm struggling to figure out how I might override a default parameter before calling it with
.run()
. Is there a way to do that?
a
Anna Geller
01/26/2022, 1:18 PM
for sure, but can you explain what exactly do you mean? Parameter defaults can be provided in their definition and when triggering a flow run, you can overwrite them e.g. the
create_flow_run
task (or mutation) allow you to pass your custom parameter values
b
Ben Welsh
01/26/2022, 1:24 PM
Ah. create_flow_run must be what I need! I'll try it. Thank you.
👍 1
Ben Welsh
01/26/2022, 1:28 PM
Here is the overly simplistic idea I'm trying that is failing. Clearly I'm missing something obvious about how to approach this.
Bring your towel and join one of the fastest growing data communities. Welcome to our second-generation open source orchestration platform, a completely rethought approach to dataflow automation.