pulumi/tests/integration/construct_component_resourc...
Abhinav Gupta a92b877e5f
sdk/go: Propagate more resource options from provider.Construct
`provider.Construct` is used to build MLCs in Go.
It receives a pulumirpc.ConstructRequest
and turns that into a standard Go SDK ResourceOption.

In #12682, we added a few new fields to pulumirpc.ConstructRequest.
This updates the Go SDK to pick up these new options
and pass them on for the resource to pick up
(and eventually send back to the engine as a RegisterResource call).

Testing:
This change includes unit tests to verify mapping of ConstructRequests
to options, which are then interpreted with NewResourceOptions.

On top of that, it builds upon the integration test added in #12699
to verify options that are saved in snapshots.
Note that this integration test does not test for the following options:
IgnoreChanges, ReplaceOnChanges, and DeleteBeforeReplace.
These options are not stored in state snapshots,
so we can't validate them just by looking at that.

Refs #12154
2023-04-21 10:58:59 -07:00
..
go sdk/go: Propagate more resource options from provider.Construct 2023-04-21 10:58:59 -07:00
testcomponent-go test(go): Integration test for MLC options 2023-04-18 13:22:52 -07:00