This message was deleted.
# general
s
This message was deleted.
e
That is, when application code is considered to have sufficient unit testing, why would unit testing for infrastructure ever be needed?
l
If you're just using Pulumi as a scripting tool, creating a pile of resources in sequence: limited.
I create a lot of ComponentResources, with logic about how to create resources, how to derive some inputs from others, and other things that can go wrong.
That needs a lot of unit testing. It's not the infra that I'm testing, it's my input-to-input and input-to-resources logic.
e
Yeah that makes sense. Are there any samples available that aren’t so trivial?
l
I haven't found any, other than my own. This example is better than the one in the Pulumi examples repo: https://github.com/jen20/pulumi-aws-vpc/blob/master/nodejs/tests/subnetDistributor.spec.ts
e
nice! thanks for sharing that.
👍 1