Documentation
¶
Overview ¶
Package testutil contains the common test utilities.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( BlockData map[string]*Block BlockHashData map[string]string MempoolData map[string]map[string]*MempoolEntry )
Functions ¶
func CheckEqual ¶
func CheckEqual(a, b interface{}) error
func CheckPctDiff ¶
checkPctDiff checks to see whether a is within p*100% of b, returning an error if not.
Types ¶
type Block ¶
type Block struct { Height_ int64 `json:"height"` Size_ int64 `json:"size"` Txids_ []string `json:"tx"` Difficulty float64 `json:"difficulty"` }
type MempoolEntry ¶
type MempoolEntry struct { Size int64 `json:"size"` Time int64 `json:"time"` Depends []string `json:"depends"` Fee float64 `json:"fee"` CurrentPriority float64 `json:"currentpriority"` }
func (*MempoolEntry) FeeRate ¶
func (m *MempoolEntry) FeeRate() int64
Returns the tx fee rate in satoshis / kB Panics if called with a zero-value receiver
func (*MempoolEntry) IsHighPriority ¶
func (m *MempoolEntry) IsHighPriority() bool
Whether or not the tx is "high priority". We don't want to use these txs to estimate miner's min fee rate policies.
Click to show internal directories.
Click to hide internal directories.