mirror of
https://github.com/imgproxy/imgproxy.git
synced 2025-09-27 20:17:20 +02:00
IMG-51: router -> server ns, handlers ns, added error to handler ret val (#1494)
* Introduced server, handlers, error ret in handlerfn * Server struct with tests * replace checkErr with return
This commit is contained in:
@@ -22,7 +22,7 @@ import (
|
||||
"github.com/imgproxy/imgproxy/v3/imagedata"
|
||||
"github.com/imgproxy/imgproxy/v3/imagetype"
|
||||
"github.com/imgproxy/imgproxy/v3/options"
|
||||
"github.com/imgproxy/imgproxy/v3/router"
|
||||
"github.com/imgproxy/imgproxy/v3/server"
|
||||
"github.com/imgproxy/imgproxy/v3/svg"
|
||||
"github.com/imgproxy/imgproxy/v3/testutil"
|
||||
"github.com/imgproxy/imgproxy/v3/vips"
|
||||
@@ -31,7 +31,7 @@ import (
|
||||
type ProcessingHandlerTestSuite struct {
|
||||
suite.Suite
|
||||
|
||||
router *router.Router
|
||||
router *server.Router
|
||||
}
|
||||
|
||||
func (s *ProcessingHandlerTestSuite) SetupSuite() {
|
||||
@@ -48,7 +48,7 @@ func (s *ProcessingHandlerTestSuite) SetupSuite() {
|
||||
|
||||
logrus.SetOutput(io.Discard)
|
||||
|
||||
s.router = buildRouter()
|
||||
s.router = buildRouter(server.NewRouter(server.NewConfigFromEnv()))
|
||||
}
|
||||
|
||||
func (s *ProcessingHandlerTestSuite) TeardownSuite() {
|
||||
|
Reference in New Issue
Block a user