// Code generated by protoc-gen-grpc-mock. DO NOT EDIT.
// source: automate-gateway/api/gateway/gateway.proto

package gateway

import (
	"context"

	"google.golang.org/grpc/codes"
	"google.golang.org/grpc/status"
	emptypb "google.golang.org/protobuf/types/known/emptypb"
)

// verify that the mock satisfies the GatewayServer interface (at compile time)
var _ GatewayServer = &GatewayServerMock{}

// NewGatewayServerMock gives you a fresh instance of GatewayServerMock.
func NewGatewayServerMock() *GatewayServerMock {
	return &GatewayServerMock{validateRequests: true}
}

// NewGatewayServerMockWithoutValidation gives you a fresh instance of
// GatewayServerMock which does not attempt to validate requests before passing
// them to their respective '*Func'.
func NewGatewayServerMockWithoutValidation() *GatewayServerMock {
	return &GatewayServerMock{}
}

// GatewayServerMock is the mock-what-you-want struct that stubs all not-overridden
// methods with "not implemented" returns
type GatewayServerMock struct {
	validateRequests bool
	GetVersionFunc   func(context.Context, *emptypb.Empty) (*Version, error)
	GetHealthFunc    func(context.Context, *emptypb.Empty) (*Health, error)
}

func (m *GatewayServerMock) GetVersion(ctx context.Context, req *emptypb.Empty) (*Version, error) {
	if msg, ok := interface{}(req).(interface{ Validate() error }); m.validateRequests && ok {
		if err := msg.Validate(); err != nil {
			return nil, status.Error(codes.InvalidArgument, err.Error())
		}
	}
	if f := m.GetVersionFunc; f != nil {
		return f(ctx, req)
	}
	return nil, status.Error(codes.Internal, "mock: 'GetVersion' not implemented")
}

func (m *GatewayServerMock) GetHealth(ctx context.Context, req *emptypb.Empty) (*Health, error) {
	if msg, ok := interface{}(req).(interface{ Validate() error }); m.validateRequests && ok {
		if err := msg.Validate(); err != nil {
			return nil, status.Error(codes.InvalidArgument, err.Error())
		}
	}
	if f := m.GetHealthFunc; f != nil {
		return f(ctx, req)
	}
	return nil, status.Error(codes.Internal, "mock: 'GetHealth' not implemented")
}

// Reset resets all overridden functions
func (m *GatewayServerMock) Reset() {
	m.GetVersionFunc = nil
	m.GetHealthFunc = nil
}
