test(bootstrap): add unit tests for initial bootstrap behavior
SonarQube Scan / SonarQube Trigger (push) Successful in 2m30s

This commit is contained in:
2026-01-24 15:42:30 +07:00
parent 1171b18340
commit 42c428c83d
9 changed files with 754 additions and 89 deletions
+8 -1
View File
@@ -5,6 +5,8 @@ import (
"log"
"os"
"tunnel_pls/internal/bootstrap"
"tunnel_pls/internal/config"
"tunnel_pls/internal/port"
"tunnel_pls/internal/version"
)
@@ -18,7 +20,12 @@ func main() {
log.SetFlags(log.LstdFlags | log.Lshortfile)
log.Printf("Starting %s", version.GetVersion())
boot, err := bootstrap.New()
conf, err := config.MustLoad()
if err != nil {
log.Fatalf("Config load error: %v", err)
}
boot, err := bootstrap.New(conf, port.New())
if err != nil {
log.Fatalf("Startup error: %v", err)
}