consul/agent/log-drop/mock_SinkAdapter.go
Dhia Ayachi 2d902b26ac
add log-drop package (#15670)
* add log-drop package

* refactor to extract level

* extract metrics

* Apply suggestions from code review

Co-authored-by: Dan Upton <daniel@floppy.co>

* fix compile errors

* change to implement a log sink

* fix tests to remove sleep

* rename and add go docs

* fix expending variadic

Co-authored-by: Dan Upton <daniel@floppy.co>
2022-12-15 12:52:48 -05:00

34 lines
935 B
Go

// Code generated by mockery v2.12.2. DO NOT EDIT.
package logdrop
import (
hclog "github.com/hashicorp/go-hclog"
mock "github.com/stretchr/testify/mock"
testing "testing"
)
// MockSinkAdapter is an autogenerated mock type for the SinkAdapter type
type MockSinkAdapter struct {
mock.Mock
}
// Accept provides a mock function with given fields: name, level, msg, args
func (_m *MockSinkAdapter) Accept(name string, level hclog.Level, msg string, args ...interface{}) {
var _ca []interface{}
_ca = append(_ca, name, level, msg)
_ca = append(_ca, args...)
_m.Called(_ca...)
}
// NewMockSinkAdapter creates a new instance of MockSinkAdapter. It also registers the testing.TB interface on the mock and a cleanup function to assert the mocks expectations.
func NewMockSinkAdapter(t testing.TB) *MockSinkAdapter {
mock := &MockSinkAdapter{}
mock.Mock.Test(t)
t.Cleanup(func() { mock.AssertExpectations(t) })
return mock
}