updated the installer so that it should actually work
Some checks failed
Build / build (push) Failing after 5m23s

This commit is contained in:
tumillanino
2025-11-11 18:57:02 +11:00
parent a7bd4d9457
commit 33dd952ad4
583 changed files with 161651 additions and 67 deletions

View File

@@ -0,0 +1,34 @@
package network
import (
"testing"
"github.com/stretchr/testify/assert"
)
func TestBackendType_Constants(t *testing.T) {
assert.Equal(t, BackendType(0), BackendNone)
assert.Equal(t, BackendType(1), BackendNetworkManager)
assert.Equal(t, BackendType(2), BackendIwd)
assert.Equal(t, BackendType(3), BackendConnMan)
assert.Equal(t, BackendType(4), BackendNetworkd)
}
func TestDetectResult_HasNetworkdField(t *testing.T) {
result := &DetectResult{
Backend: BackendNetworkd,
HasNetworkd: true,
HasIwd: true,
}
assert.True(t, result.HasNetworkd)
assert.True(t, result.HasIwd)
assert.Equal(t, BackendNetworkd, result.Backend)
}
func TestDetectNetworkStack_Integration(t *testing.T) {
result, err := DetectNetworkStack()
assert.NoError(t, err)
assert.NotNil(t, result)
assert.NotEmpty(t, result.ChosenReason)
}