fix: failing compilation and failing tests
nclazz/soundwerft/pipeline/head This commit looks good
Details
nclazz/soundwerft/pipeline/head This commit looks good
Details
parent
0d34ef4702
commit
cc1ca20161
2
Makefile
2
Makefile
|
@ -1,7 +1,7 @@
|
|||
.DEFAULT_GOAL: all
|
||||
|
||||
.PHONY: all
|
||||
all: check build ## Build and test the complete project
|
||||
all: generate check build ## Build and test the complete project
|
||||
|
||||
.PHONY: help
|
||||
help: ## Display this help
|
||||
|
|
|
@ -2,6 +2,7 @@ package integrationtest
|
|||
|
||||
import (
|
||||
"git.l--n.de/nclazz/soundwerft/api"
|
||||
"git.l--n.de/nclazz/soundwerft/internal/app"
|
||||
"git.l--n.de/nclazz/soundwerft/pkg/localizer"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/stretchr/testify/assert"
|
||||
|
@ -12,6 +13,8 @@ import (
|
|||
|
||||
func TestSetupApi(t *testing.T) {
|
||||
server := api.New(
|
||||
&app.Services{},
|
||||
&app.Repositories{},
|
||||
api.WithRandomPort(),
|
||||
api.WithWorkingDir("../.."),
|
||||
api.WithLocalizer(localizer.NewMock()),
|
||||
|
|
|
@ -3,6 +3,8 @@ package testutils
|
|||
import (
|
||||
"git.l--n.de/nclazz/soundwerft/api/handler"
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/nicksnyder/go-i18n/v2/i18n"
|
||||
"golang.org/x/text/language"
|
||||
)
|
||||
|
||||
type HandlerFactory struct {
|
||||
|
@ -23,7 +25,9 @@ func NewHandlerFactory(opts ...HandlerFactoryOption) *HandlerFactory {
|
|||
}
|
||||
|
||||
func (h *HandlerFactory) NewMockHandler() *handler.Handler {
|
||||
bundle := i18n.NewBundle(language.English)
|
||||
return &handler.Handler{
|
||||
Echo: h.Echo,
|
||||
Echo: h.Echo,
|
||||
Localizer: i18n.NewLocalizer(bundle),
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue