Documentation ¶
Index ¶
- func NewCustomTestRemoteDcrwallet(t TB, nodeName, dataDir string, hdSeed, privatePass []byte, ...) (*grpc.ClientConn, func())
- func NewRPCSyncingTestRemoteDcrwallet(t TB, dcrd *rpcclient.ConnConfig) (*grpc.ClientConn, func())
- func NewRPCSyncingTestWallet(t TB, rpcConfig *rpcclient.ConnConfig) (*wallet.Wallet, func())
- func NewSPVSyncingTestRemoteDcrwallet(t TB, p2pAddr string) (*grpc.ClientConn, func())
- func NewSPVSyncingTestWallet(t TB, p2pAddr string) (*wallet.Wallet, func())
- func NewSetupRPCTest(ctx context.Context, maxTries int, netParams *chaincfg.Params, ...) (*rpctest.Harness, error)
- func SetPerAccountPassphrase(conn *grpc.ClientConn, passphrase []byte) error
- type SPVConfig
- type TB
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCustomTestRemoteDcrwallet ¶
func NewCustomTestRemoteDcrwallet(t TB, nodeName, dataDir string, hdSeed, privatePass []byte, dcrd *rpcclient.ConnConfig, spv *SPVConfig) (*grpc.ClientConn, func())
NewCustomTestRemoteDcrwallet runs a dcrwallet instance for use during tests.
func NewRPCSyncingTestRemoteDcrwallet ¶ added in v0.5.0
func NewRPCSyncingTestRemoteDcrwallet(t TB, dcrd *rpcclient.ConnConfig) (*grpc.ClientConn, func())
NewRPCSyncingTestRemoteDcrwallet creates a new dcrwallet process that can be used by a remotedcrwallet instance to perform the interface tests. This remote wallet syncs to the passed dcrd node using RPC mode sycing.
This function returns the grpc conn and a cleanup function to close the wallet.
func NewRPCSyncingTestWallet ¶ added in v0.5.0
NewRPCSyncingTestWallet creates a test wallet that syncs itself using the RPC connection mode.
func NewSPVSyncingTestRemoteDcrwallet ¶ added in v0.5.0
func NewSPVSyncingTestRemoteDcrwallet(t TB, p2pAddr string) (*grpc.ClientConn, func())
NewRPCSyncingTestRemoteDcrwallet creates a new dcrwallet process that can be used by a remotedcrwallet instance to perform the interface tests. This remote wallet syncs to the passed dcrd node using SPV mode sycing.
This function returns the grpc conn and a cleanup function to close the wallet.
func NewSPVSyncingTestWallet ¶ added in v0.5.0
NewSPVSyncingTestWallet creates a test wallet that syncs itself using the SPV connection mode.
func NewSetupRPCTest ¶
func NewSetupRPCTest(ctx context.Context, maxTries int, netParams *chaincfg.Params, handlers *rpcclient.NotificationHandlers, args []string, setupChain bool, numMatureOutputs uint32) (*rpctest.Harness, error)
NewSetupRPCTest attempts up to maxTries to setup an rpctest harness or errors. This is used to get around the fact the rpctest does not validate listening addresses beforehand and might try to listen on an used address in CI servers.
The returned rpctest is already setup for use.
func SetPerAccountPassphrase ¶ added in v0.3.3
func SetPerAccountPassphrase(conn *grpc.ClientConn, passphrase []byte) error
SetPerAccountPassphrase calls the SetAccountPassphrase rpc endpoint on the wallet at the given conn, setting it to the specified passphrse.
This function expects a conn returned by NewCustomTestRemoteDcrwallet.