multi: introduce new paymentsDB package
We introduce a new package paymentsDB and start by moving the payment specifc errors from the channeldb package to the paymentsDB package. We also fix linter issues which showed up due to changing this code part.
This commit is contained in:
12 files changed
+279
-261
No files matched your search
@@ -13,6 +13,7 @@ import (
|
||||
"github.com/davecgh/go-spew/spew"
|
||||
"github.com/lightningnetwork/lnd/channeldb"
|
||||
"github.com/lightningnetwork/lnd/lntypes"
|
||||
paymentsdb "github.com/lightningnetwork/lnd/payments/db"
|
||||
"github.com/lightningnetwork/lnd/routing/route"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
@@ -53,7 +54,7 @@ func TestControlTowerSubscribeUnknown(t *testing.T) {
|
||||
|
||||
// Subscription should fail when the payment is not known.
|
||||
_, err := pControl.SubscribePayment(lntypes.Hash{1})
|
||||
require.ErrorIs(t, err, channeldb.ErrPaymentNotInitiated)
|
||||
require.ErrorIs(t, err, paymentsdb.ErrPaymentNotInitiated)
|
||||
}
|
||||
|
||||
// TestControlTowerSubscribeSuccess tests that payment updates for a
|
||||
|
||||
Reference in new issue
Block a user