joneshf / terraform-provider-openwrt

A Terraform provider for OpenWrt using LuCI's JSON-RPC API
https://registry.terraform.io/providers/joneshf/openwrt
Mozilla Public License 2.0
33 stars 8 forks source link

Move LuCI JSON-RPC client to `OpenWrtServer` #123

Closed joneshf closed 1 year ago

joneshf commented 1 year ago

We had a couple of helpers to remove some of the bookkeeping of setting up the tests. This seemed like a good idea at the time, but it meant that we'd end up with awkward names for the helpers we made.

As we add more tests with different requirements, it's actually harder to know what to use in each test with the helpers. So, we ditch them in exchange for calling each thing explicitly.

This is a bit more work for each call-site, but it means that we don't have to keep inventing new func names that don't accurately describe what they're doing, or when to use them.