Rendering: Remove SVG sanitization (#109797)
This commit is contained in:
@@ -1,21 +1,27 @@
|
||||
// Code generated by MockGen. DO NOT EDIT.
|
||||
// Source: github.com/grafana/grafana/pkg/services/rendering (interfaces: Service)
|
||||
//
|
||||
// Generated by this command:
|
||||
//
|
||||
// mockgen -destination=mock.go -package=rendering github.com/grafana/grafana/pkg/services/rendering Service
|
||||
//
|
||||
|
||||
// Package rendering is a generated GoMock package.
|
||||
package rendering
|
||||
|
||||
import (
|
||||
context "context"
|
||||
reflect "reflect"
|
||||
|
||||
gomock "github.com/golang/mock/gomock"
|
||||
|
||||
models "github.com/grafana/grafana/pkg/models"
|
||||
gomock "go.uber.org/mock/gomock"
|
||||
)
|
||||
|
||||
// MockService is a mock of Service interface.
|
||||
type MockService struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockServiceMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockServiceMockRecorder is the mock recorder for MockService.
|
||||
@@ -45,7 +51,7 @@ func (m *MockService) CreateRenderingSession(ctx context.Context, authOpts AuthO
|
||||
}
|
||||
|
||||
// CreateRenderingSession indicates an expected call of CreateRenderingSession.
|
||||
func (mr *MockServiceMockRecorder) CreateRenderingSession(ctx, authOpts, sessionOpts interface{}) *gomock.Call {
|
||||
func (mr *MockServiceMockRecorder) CreateRenderingSession(ctx, authOpts, sessionOpts any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateRenderingSession", reflect.TypeOf((*MockService)(nil).CreateRenderingSession), ctx, authOpts, sessionOpts)
|
||||
}
|
||||
@@ -60,7 +66,7 @@ func (m *MockService) GetRenderUser(ctx context.Context, key string) (*RenderUse
|
||||
}
|
||||
|
||||
// GetRenderUser indicates an expected call of GetRenderUser.
|
||||
func (mr *MockServiceMockRecorder) GetRenderUser(ctx, key interface{}) *gomock.Call {
|
||||
func (mr *MockServiceMockRecorder) GetRenderUser(ctx, key any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetRenderUser", reflect.TypeOf((*MockService)(nil).GetRenderUser), ctx, key)
|
||||
}
|
||||
@@ -75,25 +81,11 @@ func (m *MockService) HasCapability(ctx context.Context, capability CapabilityNa
|
||||
}
|
||||
|
||||
// HasCapability indicates an expected call of HasCapability.
|
||||
func (mr *MockServiceMockRecorder) HasCapability(ctx, capability interface{}) *gomock.Call {
|
||||
func (mr *MockServiceMockRecorder) HasCapability(ctx, capability any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "HasCapability", reflect.TypeOf((*MockService)(nil).HasCapability), ctx, capability)
|
||||
}
|
||||
|
||||
// IsCapabilitySupported mocks base method.
|
||||
func (m *MockService) IsCapabilitySupported(ctx context.Context, capability CapabilityName) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "IsCapabilitySupported", ctx, capability)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// IsCapabilitySupported indicates an expected call of IsCapabilitySupported.
|
||||
func (mr *MockServiceMockRecorder) IsCapabilitySupported(ctx, capability interface{}) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IsCapabilitySupported", reflect.TypeOf((*MockService)(nil).IsCapabilitySupported), ctx, capability)
|
||||
}
|
||||
|
||||
// IsAvailable mocks base method.
|
||||
func (m *MockService) IsAvailable(ctx context.Context) bool {
|
||||
m.ctrl.T.Helper()
|
||||
@@ -103,11 +95,25 @@ func (m *MockService) IsAvailable(ctx context.Context) bool {
|
||||
}
|
||||
|
||||
// IsAvailable indicates an expected call of IsAvailable.
|
||||
func (mr *MockServiceMockRecorder) IsAvailable(ctx interface{}) *gomock.Call {
|
||||
func (mr *MockServiceMockRecorder) IsAvailable(ctx any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IsAvailable", reflect.TypeOf((*MockService)(nil).IsAvailable), ctx)
|
||||
}
|
||||
|
||||
// IsCapabilitySupported mocks base method.
|
||||
func (m *MockService) IsCapabilitySupported(ctx context.Context, capability CapabilityName) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "IsCapabilitySupported", ctx, capability)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// IsCapabilitySupported indicates an expected call of IsCapabilitySupported.
|
||||
func (mr *MockServiceMockRecorder) IsCapabilitySupported(ctx, capability any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IsCapabilitySupported", reflect.TypeOf((*MockService)(nil).IsCapabilitySupported), ctx, capability)
|
||||
}
|
||||
|
||||
// Render mocks base method.
|
||||
func (m *MockService) Render(ctx context.Context, renderType RenderType, opts Opts, session Session) (*RenderResult, error) {
|
||||
m.ctrl.T.Helper()
|
||||
@@ -118,7 +124,7 @@ func (m *MockService) Render(ctx context.Context, renderType RenderType, opts Op
|
||||
}
|
||||
|
||||
// Render indicates an expected call of Render.
|
||||
func (mr *MockServiceMockRecorder) Render(ctx, renderType, opts, session interface{}) *gomock.Call {
|
||||
func (mr *MockServiceMockRecorder) Render(ctx, renderType, opts, session any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Render", reflect.TypeOf((*MockService)(nil).Render), ctx, renderType, opts, session)
|
||||
}
|
||||
@@ -133,7 +139,7 @@ func (m *MockService) RenderCSV(ctx context.Context, opts CSVOpts, session Sessi
|
||||
}
|
||||
|
||||
// RenderCSV indicates an expected call of RenderCSV.
|
||||
func (mr *MockServiceMockRecorder) RenderCSV(ctx, opts, session interface{}) *gomock.Call {
|
||||
func (mr *MockServiceMockRecorder) RenderCSV(ctx, opts, session any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RenderCSV", reflect.TypeOf((*MockService)(nil).RenderCSV), ctx, opts, session)
|
||||
}
|
||||
@@ -148,24 +154,9 @@ func (m *MockService) RenderErrorImage(theme models.Theme, err error) (*RenderRe
|
||||
}
|
||||
|
||||
// RenderErrorImage indicates an expected call of RenderErrorImage.
|
||||
func (mr *MockServiceMockRecorder) RenderErrorImage(theme, error interface{}) *gomock.Call {
|
||||
func (mr *MockServiceMockRecorder) RenderErrorImage(theme, err any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RenderErrorImage", reflect.TypeOf((*MockService)(nil).RenderErrorImage), theme, error)
|
||||
}
|
||||
|
||||
// SanitizeSVG mocks base method.
|
||||
func (m *MockService) SanitizeSVG(ctx context.Context, req *SanitizeSVGRequest) (*SanitizeSVGResponse, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "SanitizeSVG", ctx, req)
|
||||
ret0, _ := ret[0].(*SanitizeSVGResponse)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// SanitizeSVG indicates an expected call of SanitizeSVG.
|
||||
func (mr *MockServiceMockRecorder) SanitizeSVG(ctx, req interface{}) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SanitizeSVG", reflect.TypeOf((*MockService)(nil).SanitizeSVG), ctx, req)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RenderErrorImage", reflect.TypeOf((*MockService)(nil).RenderErrorImage), theme, err)
|
||||
}
|
||||
|
||||
// Version mocks base method.
|
||||
|
||||
Reference in New Issue
Block a user