add convenience method to pull params from config

This commit is contained in:
Joel Wetzell
2026-03-01 14:57:19 -06:00
parent 183182e6cd
commit c298f63ffc
69 changed files with 591 additions and 1081 deletions

View File

@@ -47,7 +47,7 @@ func TestBadUDPClient(t *testing.T) {
params: map[string]any{
"host": "localhost",
},
errorString: "net.udp.client requires a port parameter",
errorString: "net.udp.client port error: not found",
},
{
name: "non-number port param",
@@ -55,14 +55,14 @@ func TestBadUDPClient(t *testing.T) {
"host": "localhost",
"port": "8000",
},
errorString: "net.udp.client port must be a number",
errorString: "net.udp.client port error: not a number",
},
{
name: "no host param",
params: map[string]any{
"port": 8000.0,
},
errorString: "net.udp.client requires a host parameter",
errorString: "net.udp.client host error: not found",
},
{
name: "non-string host param",
@@ -70,7 +70,7 @@ func TestBadUDPClient(t *testing.T) {
"host": 123,
"port": 8000.0,
},
errorString: "net.udp.client host must be a string",
errorString: "net.udp.client host error: not a string",
},
}