Initial commit
CI / test (push) Canceled after 0s

This commit is contained in:
2026-09-12 22:22:17 +02:00
commit 904d14b64c
314 changed files with 31884 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
package main
import "testing"
func TestConfigFromEnvironment(t *testing.T) {
t.Setenv("GARDOMATIC_WEB_HOST", "0.0.0.0")
t.Setenv("GARDOMATIC_WEB_PORT", "4444")
t.Setenv("GARDOMATIC_API_BASE_URL", "https://api.example.com")
cfg, err := configFromEnvironment()
if err != nil {
t.Fatal(err)
}
if cfg.Host != "0.0.0.0" || cfg.Port != 4444 || cfg.APIBaseURL != "https://api.example.com" {
t.Fatalf("unexpected config: %#v", cfg)
}
}