// Code generated by mockery; DO NOT EDIT. // github.com/vektra/mockery // template: testify package mocks import ( "github.com/btcsuite/btcd/btcec/v2" "github.com/getAlby/hub/config" mock "github.com/stretchr/testify/mock" "github.com/tyler-smith/go-bip32" ) // NewMockKeys creates a new instance of MockKeys. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. // The first argument is typically a *testing.T value. func NewMockKeys(t interface { mock.TestingT Cleanup(func()) }) *MockKeys { mock := &MockKeys{} mock.Mock.Test(t) t.Cleanup(func() { mock.AssertExpectations(t) }) return mock } // MockKeys is an autogenerated mock type for the Keys type type MockKeys struct { mock.Mock } type MockKeys_Expecter struct { mock *mock.Mock } func (_m *MockKeys) EXPECT() *MockKeys_Expecter { return &MockKeys_Expecter{mock: &_m.Mock} } // DeriveKey provides a mock function for the type MockKeys func (_mock *MockKeys) DeriveKey(path []uint32) (*bip32.Key, error) { ret := _mock.Called(path) if len(ret) == 0 { panic("no return value specified for DeriveKey") } var r0 *bip32.Key var r1 error if returnFunc, ok := ret.Get(0).(func([]uint32) (*bip32.Key, error)); ok { return returnFunc(path) } if returnFunc, ok := ret.Get(0).(func([]uint32) *bip32.Key); ok { r0 = returnFunc(path) } else { if ret.Get(0) != nil { r0 = ret.Get(0).(*bip32.Key) } } if returnFunc, ok := ret.Get(1).(func([]uint32) error); ok { r1 = returnFunc(path) } else { r1 = ret.Error(1) } return r0, r1 } // MockKeys_DeriveKey_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeriveKey' type MockKeys_DeriveKey_Call struct { *mock.Call } // DeriveKey is a helper method to define mock.On call // - path []uint32 func (_e *MockKeys_Expecter) DeriveKey(path interface{}) *MockKeys_DeriveKey_Call { return &MockKeys_DeriveKey_Call{Call: _e.mock.On("DeriveKey", path)} } func (_c *MockKeys_DeriveKey_Call) Run(run func(path []uint32)) *MockKeys_DeriveKey_Call { _c.Call.Run(func(args mock.Arguments) { var arg0 []uint32 if args[0] != nil { arg0 = args[0].([]uint32) } run( arg0, ) }) return _c } func (_c *MockKeys_DeriveKey_Call) Return(key *bip32.Key, err error) *MockKeys_DeriveKey_Call { _c.Call.Return(key, err) return _c } func (_c *MockKeys_DeriveKey_Call) RunAndReturn(run func(path []uint32) (*bip32.Key, error)) *MockKeys_DeriveKey_Call { _c.Call.Return(run) return _c } // GetAppWalletKey provides a mock function for the type MockKeys func (_mock *MockKeys) GetAppWalletKey(childIndex uint) (string, error) { ret := _mock.Called(childIndex) if len(ret) == 0 { panic("no return value specified for GetAppWalletKey") } var r0 string var r1 error if returnFunc, ok := ret.Get(0).(func(uint) (string, error)); ok { return returnFunc(childIndex) } if returnFunc, ok := ret.Get(0).(func(uint) string); ok { r0 = returnFunc(childIndex) } else { r0 = ret.Get(0).(string) } if returnFunc, ok := ret.Get(1).(func(uint) error); ok { r1 = returnFunc(childIndex) } else { r1 = ret.Error(1) } return r0, r1 } // MockKeys_GetAppWalletKey_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetAppWalletKey' type MockKeys_GetAppWalletKey_Call struct { *mock.Call } // GetAppWalletKey is a helper method to define mock.On call // - childIndex uint func (_e *MockKeys_Expecter) GetAppWalletKey(childIndex interface{}) *MockKeys_GetAppWalletKey_Call { return &MockKeys_GetAppWalletKey_Call{Call: _e.mock.On("GetAppWalletKey", childIndex)} } func (_c *MockKeys_GetAppWalletKey_Call) Run(run func(childIndex uint)) *MockKeys_GetAppWalletKey_Call { _c.Call.Run(func(args mock.Arguments) { var arg0 uint if args[0] != nil { arg0 = args[0].(uint) } run( arg0, ) }) return _c } func (_c *MockKeys_GetAppWalletKey_Call) Return(s string, err error) *MockKeys_GetAppWalletKey_Call { _c.Call.Return(s, err) return _c } func (_c *MockKeys_GetAppWalletKey_Call) RunAndReturn(run func(childIndex uint) (string, error)) *MockKeys_GetAppWalletKey_Call { _c.Call.Return(run) return _c } // GetNostrPublicKey provides a mock function for the type MockKeys func (_mock *MockKeys) GetNostrPublicKey() string { ret := _mock.Called() if len(ret) == 0 { panic("no return value specified for GetNostrPublicKey") } var r0 string if returnFunc, ok := ret.Get(0).(func() string); ok { r0 = returnFunc() } else { r0 = ret.Get(0).(string) } return r0 } // MockKeys_GetNostrPublicKey_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetNostrPublicKey' type MockKeys_GetNostrPublicKey_Call struct { *mock.Call } // GetNostrPublicKey is a helper method to define mock.On call func (_e *MockKeys_Expecter) GetNostrPublicKey() *MockKeys_GetNostrPublicKey_Call { return &MockKeys_GetNostrPublicKey_Call{Call: _e.mock.On("GetNostrPublicKey")} } func (_c *MockKeys_GetNostrPublicKey_Call) Run(run func()) *MockKeys_GetNostrPublicKey_Call { _c.Call.Run(func(args mock.Arguments) { run() }) return _c } func (_c *MockKeys_GetNostrPublicKey_Call) Return(s string) *MockKeys_GetNostrPublicKey_Call { _c.Call.Return(s) return _c } func (_c *MockKeys_GetNostrPublicKey_Call) RunAndReturn(run func() string) *MockKeys_GetNostrPublicKey_Call { _c.Call.Return(run) return _c } // GetNostrSecretKey provides a mock function for the type MockKeys func (_mock *MockKeys) GetNostrSecretKey() string { ret := _mock.Called() if len(ret) == 0 { panic("no return value specified for GetNostrSecretKey") } var r0 string if returnFunc, ok := ret.Get(0).(func() string); ok { r0 = returnFunc() } else { r0 = ret.Get(0).(string) } return r0 } // MockKeys_GetNostrSecretKey_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetNostrSecretKey' type MockKeys_GetNostrSecretKey_Call struct { *mock.Call } // GetNostrSecretKey is a helper method to define mock.On call func (_e *MockKeys_Expecter) GetNostrSecretKey() *MockKeys_GetNostrSecretKey_Call { return &MockKeys_GetNostrSecretKey_Call{Call: _e.mock.On("GetNostrSecretKey")} } func (_c *MockKeys_GetNostrSecretKey_Call) Run(run func()) *MockKeys_GetNostrSecretKey_Call { _c.Call.Run(func(args mock.Arguments) { run() }) return _c } func (_c *MockKeys_GetNostrSecretKey_Call) Return(s string) *MockKeys_GetNostrSecretKey_Call { _c.Call.Return(s) return _c } func (_c *MockKeys_GetNostrSecretKey_Call) RunAndReturn(run func() string) *MockKeys_GetNostrSecretKey_Call { _c.Call.Return(run) return _c } // GetSwapKey provides a mock function for the type MockKeys func (_mock *MockKeys) GetSwapKey(childIndex uint) (*btcec.PrivateKey, error) { ret := _mock.Called(childIndex) if len(ret) == 0 { panic("no return value specified for GetSwapKey") } var r0 *btcec.PrivateKey var r1 error if returnFunc, ok := ret.Get(0).(func(uint) (*btcec.PrivateKey, error)); ok { return returnFunc(childIndex) } if returnFunc, ok := ret.Get(0).(func(uint) *btcec.PrivateKey); ok { r0 = returnFunc(childIndex) } else { if ret.Get(0) != nil { r0 = ret.Get(0).(*btcec.PrivateKey) } } if returnFunc, ok := ret.Get(1).(func(uint) error); ok { r1 = returnFunc(childIndex) } else { r1 = ret.Error(1) } return r0, r1 } // MockKeys_GetSwapKey_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetSwapKey' type MockKeys_GetSwapKey_Call struct { *mock.Call } // GetSwapKey is a helper method to define mock.On call // - childIndex uint func (_e *MockKeys_Expecter) GetSwapKey(childIndex interface{}) *MockKeys_GetSwapKey_Call { return &MockKeys_GetSwapKey_Call{Call: _e.mock.On("GetSwapKey", childIndex)} } func (_c *MockKeys_GetSwapKey_Call) Run(run func(childIndex uint)) *MockKeys_GetSwapKey_Call { _c.Call.Run(func(args mock.Arguments) { var arg0 uint if args[0] != nil { arg0 = args[0].(uint) } run( arg0, ) }) return _c } func (_c *MockKeys_GetSwapKey_Call) Return(v *btcec.PrivateKey, err error) *MockKeys_GetSwapKey_Call { _c.Call.Return(v, err) return _c } func (_c *MockKeys_GetSwapKey_Call) RunAndReturn(run func(childIndex uint) (*btcec.PrivateKey, error)) *MockKeys_GetSwapKey_Call { _c.Call.Return(run) return _c } // GetSwapMnemonic provides a mock function for the type MockKeys func (_mock *MockKeys) GetSwapMnemonic() string { ret := _mock.Called() if len(ret) == 0 { panic("no return value specified for GetSwapMnemonic") } var r0 string if returnFunc, ok := ret.Get(0).(func() string); ok { r0 = returnFunc() } else { r0 = ret.Get(0).(string) } return r0 } // MockKeys_GetSwapMnemonic_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetSwapMnemonic' type MockKeys_GetSwapMnemonic_Call struct { *mock.Call } // GetSwapMnemonic is a helper method to define mock.On call func (_e *MockKeys_Expecter) GetSwapMnemonic() *MockKeys_GetSwapMnemonic_Call { return &MockKeys_GetSwapMnemonic_Call{Call: _e.mock.On("GetSwapMnemonic")} } func (_c *MockKeys_GetSwapMnemonic_Call) Run(run func()) *MockKeys_GetSwapMnemonic_Call { _c.Call.Run(func(args mock.Arguments) { run() }) return _c } func (_c *MockKeys_GetSwapMnemonic_Call) Return(s string) *MockKeys_GetSwapMnemonic_Call { _c.Call.Return(s) return _c } func (_c *MockKeys_GetSwapMnemonic_Call) RunAndReturn(run func() string) *MockKeys_GetSwapMnemonic_Call { _c.Call.Return(run) return _c } // Init provides a mock function for the type MockKeys func (_mock *MockKeys) Init(cfg config.Config, encryptionKey string) error { ret := _mock.Called(cfg, encryptionKey) if len(ret) == 0 { panic("no return value specified for Init") } var r0 error if returnFunc, ok := ret.Get(0).(func(config.Config, string) error); ok { r0 = returnFunc(cfg, encryptionKey) } else { r0 = ret.Error(0) } return r0 } // MockKeys_Init_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Init' type MockKeys_Init_Call struct { *mock.Call } // Init is a helper method to define mock.On call // - cfg config.Config // - encryptionKey string func (_e *MockKeys_Expecter) Init(cfg interface{}, encryptionKey interface{}) *MockKeys_Init_Call { return &MockKeys_Init_Call{Call: _e.mock.On("Init", cfg, encryptionKey)} } func (_c *MockKeys_Init_Call) Run(run func(cfg config.Config, encryptionKey string)) *MockKeys_Init_Call { _c.Call.Run(func(args mock.Arguments) { var arg0 config.Config if args[0] != nil { arg0 = args[0].(config.Config) } var arg1 string if args[1] != nil { arg1 = args[1].(string) } run( arg0, arg1, ) }) return _c } func (_c *MockKeys_Init_Call) Return(err error) *MockKeys_Init_Call { _c.Call.Return(err) return _c } func (_c *MockKeys_Init_Call) RunAndReturn(run func(cfg config.Config, encryptionKey string) error) *MockKeys_Init_Call { _c.Call.Return(run) return _c }