Upstream commit b86df0ba91.
The merge commit contains necessary Decred-specific alterations and also
removes the code that is related to generating and submitting a new
block.
While the block generation functionality is useful, the specific method
used in the upstream code will not work in Decred because of the
additional state needed for voting and the fact the difficulty
adjustment period is much more frequent which prevents just using the
pow limit.
Future commits can remedy this situation by making use of block
templates provided by the daemon and allowing the rpc test code to
modify the template accordingly.
1.1 KiB
rpctest
[]
(https://travis-ci.org/decred/dcrd) ![ISC License]
(http://img.shields.io/badge/license-ISC-blue.svg)
[
]
(http://godoc.org/github.com/decred/dcrd/rpctest)
Package rpctest provides a dcrd-specific RPC testing harness crafting and
executing integration tests by driving a dcrd instance via the RPC
interface. Each instance of an active harness comes equipped with a simple
in-memory HD wallet capable of properly syncing to the generated chain,
creating new addresses, and crafting fully signed transactions paying to an
arbitrary set of outputs.
This package was designed specifically to act as an RPC testing harness for
dcrd. However, the constructs presented are general enough to be adapted to
any project wishing to programmatically drive a dcrd instance of its
systems/integration tests.
Installation and Updating
$ go get -u github.com/decred/dcrd/rpctest
License
Package rpctest is licensed under the copyfree ISC License.