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.

628 B
Raw Blame
package configapi

import (
	"testing"

	"github.com/rcourtman/pulse-go-rewrite/internal/config"
	"github.com/rcourtman/pulse-go-rewrite/pkg/proxmox"
)

func stubAutoRegisterNetworkDeps(t *testing.T) {
	t.Helper()

	originalDetect := detectPVECluster
	originalFingerprint := fetchTLSFingerprint

	detectPVECluster = func(proxmox.ClientConfig, string, []config.ClusterEndpoint) (bool, string, []config.ClusterEndpoint) {
		return false, "", nil
	}
	fetchTLSFingerprint = func(string) (string, error) {
		return "", nil
	}

	t.Cleanup(func() {
		detectPVECluster = originalDetect
		fetchTLSFingerprint = originalFingerprint
	})
}