func WithReleaseFunc(f func(peer swarm.Address, price uint64)) Option {
	return optionFunc(func(s *Service) {
		s.releaseFunc = f
	})
}
WithReleaseFunc sets the mock Release function
package mock
import (
	"context"
	"math/big"
	"sync"
	"github.com/ethsana/sana/pkg/accounting"
	"github.com/ethsana/sana/pkg/swarm"
)
type Service struct {
	lock                    sync.Mutex
	balances                map[string]*big.Int
	reserveFunc             func(ctx context.Context, peer swarm.Address, price uint64) error
	releaseFunc             func(peer swarm.Address, price uint64)
	creditFunc              func(peer swarm.Address, price uint64, orig bool) error
	prepareDebitFunc        func(peer swarm.Address, price uint64) (accounting.Action, error)
	balanceFunc             func(swarm.Address) (*big.Int, error)
	shadowBalanceFunc       func(swarm.Address) (*big.Int, error)
	balancesFunc            func() (map[string]*big.Int, error)
	compensatedBalanceFunc  func(swarm.Address) (*big.Int, error)
	compensatedBalancesFunc func() (map[string]*big.Int, error)
	balanceSurplusFunc func(swarm.Address) (*big.Int, error)
}
type debitAction struct {
	accounting *Service
	price      *big.Int
	peer       swarm.Address
	applied    bool
}
func WithReserveFunc(f func(ctx context.Context, peer swarm.Address, price uint64) error) Option {
	return optionFunc(func(s *Service) {
		s.reserveFunc = f
	})
}