mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-09-08 23:01:53 +02:00
channeldb: add k/v implementation for InvoiceDB.FetchPendingInvoices
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
package invoices
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/lightningnetwork/lnd/lntypes"
|
||||
"github.com/stretchr/testify/mock"
|
||||
)
|
||||
@@ -55,6 +57,13 @@ func (m *MockInvoiceDB) ScanInvoices(scanFunc InvScanFunc,
|
||||
return args.Error(0)
|
||||
}
|
||||
|
||||
func (m *MockInvoiceDB) FetchPendingInvoices(ctx context.Context) (
|
||||
map[lntypes.Hash]Invoice, error) {
|
||||
|
||||
args := m.Called(ctx)
|
||||
return args.Get(0).(map[lntypes.Hash]Invoice), args.Error(1)
|
||||
}
|
||||
|
||||
func (m *MockInvoiceDB) QueryInvoices(q InvoiceQuery) (InvoiceSlice, error) {
|
||||
args := m.Called(q)
|
||||
invoiceSlice, _ := args.Get(0).(InvoiceSlice)
|
||||
|
Reference in New Issue
Block a user