breezy-egg-71492
06/07/2024, 6:57 PMOutput.apply(assert_callback)
method as suggested, but we were wondering if there could be some issues in doing something like this:
@pulumi.runtime.test
async def test_cluster(self, component_parameters):
cluster = AuroraCluster(**component_parameters)
assert isinstance(cluster.cluster, aws.rds.Cluster)
assert await cluster.cluster.cluster_identifier.future() == f"{component_parameters['name']}-cluster"
It has been working great until now, considering we are using it only inside our tests. It's making it a lot easier to write and read them.
So the question is: do you think we may face some issues following this path? Is there some strange hidden behaviour or side-effect that we are not triggering using future()
with async/await
instead of the apply()
?No matter how you like to participate in developer communities, Pulumi wants to meet you there. If you want to meet other Pulumi users to share use-cases and best practices, contribute code or documentation, see us at an event, or just tell a story about something cool you did with Pulumi, you are part of our community.
Powered by