fx build fix
Some checks failed
ci/woodpecker/push/db Pipeline was successful
ci/woodpecker/push/fx/1 Pipeline failed
ci/woodpecker/push/nats Pipeline was successful
ci/woodpecker/push/fx/2 Pipeline failed

This commit is contained in:
Stephan D
2025-11-08 00:40:01 +01:00
parent 49b86efecb
commit d367dddbbd
98 changed files with 3983 additions and 5063 deletions

View File

@@ -6,17 +6,6 @@ import (
factory "github.com/tech/sendico/pkg/mlogger/factory"
)
func TestNewTaskManagerFactory(t *testing.T) {
logger := factory.NewLogger(true)
// Test that factory doesn't panic with nil dependencies
taskManager := NewTaskManager(logger, nil, nil)
if taskManager == nil {
t.Fatal("Expected non-nil TaskManager")
}
}
func TestNewAccountManagerFactory(t *testing.T) {
logger := factory.NewLogger(true)
@@ -30,38 +19,3 @@ func TestNewAccountManagerFactory(t *testing.T) {
t.Fatal("Expected non-nil AccountManager")
}
}
func TestFactoriesWithNilLogger(t *testing.T) {
// Test that factories handle nil logger gracefully
taskManager := NewTaskManager(nil, nil, nil)
if taskManager == nil {
t.Fatal("Expected non-nil TaskManager even with nil logger")
}
accountManager := NewAccountManager(
nil,
nil, nil, nil, nil,
)
if accountManager == nil {
t.Fatal("Expected non-nil AccountManager even with nil logger")
}
}
func TestFactoryTypesCompile(t *testing.T) {
// This test verifies that the factory functions return the expected interface types
logger := factory.NewLogger(true)
var taskManager TaskManager = NewTaskManager(logger, nil, nil)
var accountManager AccountManager = NewAccountManager(
logger,
nil, nil, nil, nil,
)
// These should not be nil
if taskManager == nil {
t.Fatal("TaskManager should not be nil")
}
if accountManager == nil {
t.Fatal("AccountManager should not be nil")
}
}