Commit Graph

30 Commits

Author SHA1 Message Date
Johan T. Halseth
37a6e8485b
rpctest: add witness commitment when calling CreateBlock
If we tried to include transactions having witnesses, the block would be
invalid since the witness commitment was not added.
2021-04-26 13:53:53 +02:00
Wilmer Paulino
f133593b93
build: update btcutil dependency 2021-03-29 16:59:44 -07:00
Jake Sylvestre
d08785547a docs: update shields 2021-03-05 07:45:19 -05:00
Jake Sylvestre
2a1aa5129e Add Batch JSON-RPC support (rpc client & server) 2021-02-09 09:47:46 -05:00
Olaoluwa Osuntokun
e9c7a5ac64
Merge pull request #1659 from guggero/itest-fixes
integration: optimize harness for better itest control, restore bitcoind compatibility
2020-11-13 16:05:16 -08:00
Liran Sharir
9fd26cf795 integration/rpctest: randomizes port in rpctest.New to reduce collisions 2020-11-11 11:37:34 -05:00
Oliver Gugger
65d2b7a18c
integration: allow specifying connection behavior 2020-11-11 14:29:17 +01:00
Oliver Gugger
93cc7f36cf
integration: allow overwriting address generator 2020-11-11 14:24:14 +01:00
Oliver Gugger
9250064837
integration: allow setting custom btcd exe path
To allow using a custom btcd executable, we allow specifying a path to a
file. If the path is empty, the harness will fall back to compiling one
from scratch.
2020-11-11 14:16:08 +01:00
Wilmer Paulino
266851e329
btcjson+rpcclient: support new unified softfork bitcoind format 2019-11-05 16:28:33 -08:00
Johan T. Halseth
f5b60801a5
integration/rpctest: make exec path compatible with modules
With the use of go modules, the btcdPkgPath will no longer be `github.com/btcsuite/btcd`, but end with a version string (e.g. btcd@v0.0.0-20181129140220-beb77e89572a).

This trips up build.ImportDir, which will return a ImportPath of ".", since this package cannot be found in the go path.

There are probably several ways of fixing this, by clever string magic, but seems easiest to just hardcode the btcd package name.
2018-11-29 15:13:37 +01:00
Wilmer Paulino
dfd7f6caf8
integration/rpctest: add ability to create txs without change outputs 2018-08-16 16:24:02 -07:00
Wilmer Paulino
9aa83ad423
integration/rpctest: disable the txindex by default
In this commit, we disable the txindex by default as the flag cannot be
overwritten by btcd once set.
2018-08-16 16:24:01 -07:00
Olaoluwa Osuntokun
b72e16f0d6 multi: correct all import paths 2018-05-23 16:46:15 -07:00
Olaoluwa Osuntokun
ffe4c2f0ad integration/rpctest: if unable to build btcd, use one in PATH 2018-05-23 16:46:15 -07:00
Alex
e2f65acf02 integration/rpctest: check quit in solveBlock()'s solver() closure 2018-05-23 16:46:15 -07:00
Alex
6cea610774 integration/rpctest: queue block disconnected ntfns in memwallet 2018-05-23 16:46:15 -07:00
Olaoluwa Osuntokun
3d1caa2f83 multi: update to point to roasbeef forks 2018-05-23 16:46:15 -07:00
Alex
ec228f9ff9 rpctest: Add GenerateAndSubmitBlockWithCustomCoinbaseOutputs 2018-05-23 16:46:15 -07:00
Nicola 'tekNico' Larosa
11fcd83963 btcd/multi: fix a number of typos in comments. 2018-01-25 23:23:59 -06:00
Jim Posen
11d7cae82b rpctest: Compile current version of btcd and run that.
Previously, rpctest would start a btcd node using the btcd executable
in the environment PATH. This caused difficult-to-find issues where
the code would be tested against an older version of btcd, or another
fork entirely. Now it compiles btcd the first time it is needed and
uses that fresh version when launching nodes.
2017-10-20 14:29:45 -07:00
Dave Collins
614b799198
rpcclient: Merge btcrpcclient repo. 2017-08-15 20:09:19 -05:00
Olaoluwa Osuntokun
1405670930 integration/rpctest: update API usage due to segwit 2017-08-13 23:17:40 -05:00
Olaoluwa Osuntokun
b1893ed228 chaincfg+integration: add BIP0009 deployment parameters for segwit
This commit adds set of BIP0009 (Version Bits) deployment parameters
for all networks detailing the activation parameters for the segwit
soft-fork.

Additionally, the BIP0009 integration test has been updated to test for
the proper transitioning of version bits state for the segwit soft
fork. Finally, the `getblockchaininfo` test has also been updated to
properly display the state of segwit.
2017-08-13 23:17:40 -05:00
Dave Collins
9918e2a561
multi: Update markdown files for GFM changes.
The github markdown interpreter has been changed such that it no longer
allows spaces in between the brackets and parenthesis of links and now
requires a newline in between anchors and other formatting.  This
updates all of the markdown files accordingly.

While here, it also corrects a couple of inconsistencies in some of the
README.md files.
2017-05-25 12:06:16 -05:00
Dave Collins
1ae306021e
rpctest: Make subpackage of integration.
This makes the rpctest package a subpackage of the integration package
since its primary purpose is for integration testing.
2017-05-11 15:17:29 -05:00
Olaoluwa Osuntokun
89728419b0
integration: add integration tests for the CSV-package soft-fork 2017-05-10 15:37:19 -07:00
Dave Collins
f65788d0a1
integration: Add BIP0009 state transition tests
This adds tests which exercise the BIP0009 state transitions using the
newly available soft fork status information in the getblockchaininfo
RPC.

The following is an overview of the tests added:
- Assert the chain height is 0 and the state is ThresholdDefined
- Generate 1 fewer blocks than needed to reach the first state
  transition
  - Assert chain height is expected and state is still ThresholdDefined
- Generate 1 more block to reach the first state transition
  - Assert chain height is expected and state moved to ThresholdStarted
- Generate enough blocks to reach the next state transition window, but
  only signal support in 1 fewer than the required number to achieve
  ThresholdLockedIn
- Assert chain height is expected and state is still ThresholdStarted
- Generate enough blocks to reach the next state transition window with
  only the exact number of blocks required to achieve locked in status
  signalling support
- Assert chain height is expected and state moved to ThresholdLockedIn
- Generate 1 fewer blocks than needed to reach the next state transition
- Assert chain height is expected and state is still ThresholdLockedIn
- Generate 1 more block to reach the next state transition
- Assert chain height is expected and state moved to ThresholdActive

In addition, it updates the existing BIP0009 mining tests to include
extra assertions that the chain height is at the expected height in
addition to checking that the bits are correctly set according to the
expected state.
2016-12-07 10:41:40 -06:00
Dave Collins
bfbaff9fae
integration: Add BIP9 mining tests. 2016-11-30 13:52:23 -06:00
Dave Collins
c0def9d613
integration: Initial implementation.
This introduces a new package to house tests which use the rpctest
package to programmatically drive end-to-end integration testing and
move the existing RPC integration tests into the new package.
2016-10-25 14:36:23 -05:00