Skip to content

armgit / Pulse

Public Imported from GitHub
0

Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.

Initialize persistent auth in origin lifecycle fixture

pulse-triage[bot]890887363cb0
diff --git a/internal/api/system_settings_telemetry_test.go b/internal/api/system_settings_telemetry_test.go
index 1d720765c5..bc955e59c7 100644
--- a/internal/api/system_settings_telemetry_test.go
+++ b/internal/api/system_settings_telemetry_test.go
@@ -815,6 +815,9 @@ func TestAllowedOriginsSavedEffectiveLifecycle(t *testing.T) {
t.Setenv("ALLOWED_ORIGINS", "")
t.Setenv("PULSE_DEV", "false")
t.Setenv("NODE_ENV", "production")
+ InitPersistentAuthStores(dir)
+ t.Cleanup(resetSessionStoreForTests)
+ t.Cleanup(resetCSRFStoreForTests)
cfg := &config.Config{DataPath: dir, ConfigPath: dir, AllowedOrigins: original, PublicURL: "https://pulse.example", AuthUser: "admin", AuthPass: "synthetic-unused-hash", EnvOverrides: map[string]bool{}, TLSCertFile: "synthetic-cert", TLSKeyFile: "synthetic-key"}
h, persistence, token := setupTelemetryTest(t, cfg)
initial := config.DefaultSystemSettings()