davidji99 / terraform-provider-split

Terraform Split provider
https://registry.terraform.io/providers/davidji99/split/latest
Mozilla Public License 2.0
23 stars 8 forks source link

Allow MATCHES_STRING for single string #152

Closed jramosf closed 12 months ago

jramosf commented 1 year ago

See: https://docs.split.io/reference/matcher-type#matches_string

The string (missing attribute) or strings depends on the matcher type.

jramosf commented 1 year ago

@davidji99 any chance this can get reviewed/merged? Thanks!

jramosf commented 12 months ago

Good start but there's quite more work needed. You'll need to:

  1. Modify https://github.com/davidji99/terraform-provider-split/blob/master/split/resource_split_split_definition.go#L484-L506 to actually accept the new attribute.
  2. Update the API client: https://github.com/davidji99/terraform-provider-split/blob/master/api/split_definition.go#L74
  3. Add test for the split_split_defition resource
  4. Update tests for split_split_defition

Thanks for the review @davidji99 . I've made changes to the Pull Request including checking multiple matchers at the same time, and fixed the initial typo MATCH_STRING. Tested with app.split.io and via make test and everything working ok so far.

image