generated from PenaSide/GolangTemplate
27 lines
684 B
Go
27 lines
684 B
Go
package initialize_test
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/assert"
|
|
"go.uber.org/zap"
|
|
"penahub.gitlab.yandexcloud.net/pena-services/customer/internal/initialize"
|
|
"penahub.gitlab.yandexcloud.net/pena-services/customer/internal/models"
|
|
)
|
|
|
|
func TestNewClients(t *testing.T) {
|
|
t.Run("Клиенты должны успешно инициализироваться", func(t *testing.T) {
|
|
logger := zap.New(zap.L().Core())
|
|
|
|
assert.NotPanics(t, func() {
|
|
clients := initialize.NewClients(&initialize.ClientsDeps{
|
|
Logger: logger,
|
|
AuthURL: &models.AuthMicroServiceURL{},
|
|
})
|
|
|
|
assert.NotNil(t, clients)
|
|
assert.NotNil(t, clients.AuthClient)
|
|
})
|
|
})
|
|
}
|