invoices: add RegistryConfig struct

This commit is contained in:
Joost Jager committed 2019-12-11 16:08:07 +01:00
1 parent 56282db30a
commit 499f2b16cf
4 files changed
+39 -19

No files matched your search

+12 -3
View File
@@ -71,7 +71,10 @@ func newTestContext(t *testing.T) *testContext {
}
// Instantiate and start the invoice ctx.registry.
registry := NewRegistry(cdb, testFinalCltvRejectDelta)
cfg := RegistryConfig{
FinalCltvRejectDelta: testFinalCltvRejectDelta,
}
registry := NewRegistry(cdb, &cfg)
err = registry.Start()
if err != nil {
@@ -390,7 +393,10 @@ func TestSettleHoldInvoice(t *testing.T) {
defer cleanup()
// Instantiate and start the invoice ctx.registry.
registry := NewRegistry(cdb, testFinalCltvRejectDelta)
cfg := RegistryConfig{
FinalCltvRejectDelta: testFinalCltvRejectDelta,
}
registry := NewRegistry(cdb, &cfg)
err = registry.Start()
if err != nil {
@@ -558,7 +564,10 @@ func TestCancelHoldInvoice(t *testing.T) {
defer cleanup()
// Instantiate and start the invoice ctx.registry.
registry := NewRegistry(cdb, testFinalCltvRejectDelta)
cfg := RegistryConfig{
FinalCltvRejectDelta: testFinalCltvRejectDelta,
}
registry := NewRegistry(cdb, &cfg)
err = registry.Start()
if err != nil {