droboticflow/internal/api/test_main_test.go
eust-w 71edc25724
Some checks are pending
CI / verify (push) Waiting to run
CI / docker-build (push) Waiting to run
🛡️ Require explicit Mongo runtime URI
2026-06-17 13:49:36 +08:00

14 lines
201 B
Go

package api
import (
"os"
"testing"
)
func TestMain(m *testing.M) {
if os.Getenv("MONGO_URI") == "" {
_ = os.Setenv("MONGO_URI", "mongodb://api-test-mongo.example:27017")
}
os.Exit(m.Run())
}