github.com/koko1123/flow-go-1@v0.29.6/storage/mock/dkg_state.go (about)

     1  // Code generated by mockery v2.13.1. DO NOT EDIT.
     2  
     3  package mock
     4  
     5  import (
     6  	crypto "github.com/onflow/flow-go/crypto"
     7  	flow "github.com/koko1123/flow-go-1/model/flow"
     8  
     9  	mock "github.com/stretchr/testify/mock"
    10  )
    11  
    12  // DKGState is an autogenerated mock type for the DKGState type
    13  type DKGState struct {
    14  	mock.Mock
    15  }
    16  
    17  // GetDKGEndState provides a mock function with given fields: epochCounter
    18  func (_m *DKGState) GetDKGEndState(epochCounter uint64) (flow.DKGEndState, error) {
    19  	ret := _m.Called(epochCounter)
    20  
    21  	var r0 flow.DKGEndState
    22  	if rf, ok := ret.Get(0).(func(uint64) flow.DKGEndState); ok {
    23  		r0 = rf(epochCounter)
    24  	} else {
    25  		r0 = ret.Get(0).(flow.DKGEndState)
    26  	}
    27  
    28  	var r1 error
    29  	if rf, ok := ret.Get(1).(func(uint64) error); ok {
    30  		r1 = rf(epochCounter)
    31  	} else {
    32  		r1 = ret.Error(1)
    33  	}
    34  
    35  	return r0, r1
    36  }
    37  
    38  // GetDKGStarted provides a mock function with given fields: epochCounter
    39  func (_m *DKGState) GetDKGStarted(epochCounter uint64) (bool, error) {
    40  	ret := _m.Called(epochCounter)
    41  
    42  	var r0 bool
    43  	if rf, ok := ret.Get(0).(func(uint64) bool); ok {
    44  		r0 = rf(epochCounter)
    45  	} else {
    46  		r0 = ret.Get(0).(bool)
    47  	}
    48  
    49  	var r1 error
    50  	if rf, ok := ret.Get(1).(func(uint64) error); ok {
    51  		r1 = rf(epochCounter)
    52  	} else {
    53  		r1 = ret.Error(1)
    54  	}
    55  
    56  	return r0, r1
    57  }
    58  
    59  // InsertMyBeaconPrivateKey provides a mock function with given fields: epochCounter, key
    60  func (_m *DKGState) InsertMyBeaconPrivateKey(epochCounter uint64, key crypto.PrivateKey) error {
    61  	ret := _m.Called(epochCounter, key)
    62  
    63  	var r0 error
    64  	if rf, ok := ret.Get(0).(func(uint64, crypto.PrivateKey) error); ok {
    65  		r0 = rf(epochCounter, key)
    66  	} else {
    67  		r0 = ret.Error(0)
    68  	}
    69  
    70  	return r0
    71  }
    72  
    73  // RetrieveMyBeaconPrivateKey provides a mock function with given fields: epochCounter
    74  func (_m *DKGState) RetrieveMyBeaconPrivateKey(epochCounter uint64) (crypto.PrivateKey, error) {
    75  	ret := _m.Called(epochCounter)
    76  
    77  	var r0 crypto.PrivateKey
    78  	if rf, ok := ret.Get(0).(func(uint64) crypto.PrivateKey); ok {
    79  		r0 = rf(epochCounter)
    80  	} else {
    81  		if ret.Get(0) != nil {
    82  			r0 = ret.Get(0).(crypto.PrivateKey)
    83  		}
    84  	}
    85  
    86  	var r1 error
    87  	if rf, ok := ret.Get(1).(func(uint64) error); ok {
    88  		r1 = rf(epochCounter)
    89  	} else {
    90  		r1 = ret.Error(1)
    91  	}
    92  
    93  	return r0, r1
    94  }
    95  
    96  // SetDKGEndState provides a mock function with given fields: epochCounter, endState
    97  func (_m *DKGState) SetDKGEndState(epochCounter uint64, endState flow.DKGEndState) error {
    98  	ret := _m.Called(epochCounter, endState)
    99  
   100  	var r0 error
   101  	if rf, ok := ret.Get(0).(func(uint64, flow.DKGEndState) error); ok {
   102  		r0 = rf(epochCounter, endState)
   103  	} else {
   104  		r0 = ret.Error(0)
   105  	}
   106  
   107  	return r0
   108  }
   109  
   110  // SetDKGStarted provides a mock function with given fields: epochCounter
   111  func (_m *DKGState) SetDKGStarted(epochCounter uint64) error {
   112  	ret := _m.Called(epochCounter)
   113  
   114  	var r0 error
   115  	if rf, ok := ret.Get(0).(func(uint64) error); ok {
   116  		r0 = rf(epochCounter)
   117  	} else {
   118  		r0 = ret.Error(0)
   119  	}
   120  
   121  	return r0
   122  }
   123  
   124  type mockConstructorTestingTNewDKGState interface {
   125  	mock.TestingT
   126  	Cleanup(func())
   127  }
   128  
   129  // NewDKGState creates a new instance of DKGState. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
   130  func NewDKGState(t mockConstructorTestingTNewDKGState) *DKGState {
   131  	mock := &DKGState{}
   132  	mock.Mock.Test(t)
   133  
   134  	t.Cleanup(func() { mock.AssertExpectations(t) })
   135  
   136  	return mock
   137  }