aboutsummaryrefslogtreecommitdiff
path: root/src/test/versionbits_tests.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Update miner confirmation windowRoss Nicoll2018-09-231-15/+15
| | | | | | * Update miner confirmation window to 240 for Dogecoin main net, and update related values. * Re-enable PoW tests with Dogecoin values. * Update version bit tests based on Dogecoin mining values.
* Modify chain consensus parameters to be height aware (#1396)Ross Nicoll2018-09-191-2/+2
| | | | | | | | | * Modify chain consensus parameters to be height aware * Correct implementation of simplified rewards in parameters * Correct max money * Use base block version in IsSuperMajority() instead of full version * Correct mining of blocks in AuxPoW tests * Add in missing pre-AuxPoW consensus checks
* Remove redundant semicolonspracticalswift2017-01-141-1/+1
|
* Rename the remaining main.{h,cpp} to validation.{h,cpp}Matt Corallo2016-12-021-1/+1
|
* test: Fix test_random includesMarcoFalke2016-11-071-1/+1
|
* RPC: augment getblockchaininfo bip9_softforks datamruddy2016-10-191-41/+63
|
* Kill insecure_random and associated global stateWladimir J. van der Laan2016-10-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There are only a few uses of `insecure_random` outside the tests. This PR replaces uses of insecure_random (and its accompanying global state) in the core code with an FastRandomContext that is automatically seeded on creation. This is meant to be used for inner loops. The FastRandomContext can be in the outer scope, or the class itself, then rand32() is used inside the loop. Useful e.g. for pushing addresses in CNode or the fee rounding, or randomization for coin selection. As a context is created per purpose, thus it gets rid of cross-thread unprotected shared usage of a single set of globals, this should also get rid of the potential race conditions. - I'd say TxMempool::check is not called enough to warrant using a special fast random context, this is switched to GetRand() (open for discussion...) - The use of `insecure_rand` in ConnectThroughProxy has been replaced by an atomic integer counter. The only goal here is to have a different credentials pair for each connection to go on a different Tor circuit, it does not need to be random nor unpredictable. - To avoid having a FastRandomContext on every CNode, the context is passed into PushAddress as appropriate. There remains an insecure_random for test usage in `test_random.h`.
* Test versionbits deploymentsSuhas Daftuar2016-03-151-0/+22
|
* Add testing of ComputeBlockVersionSuhas Daftuar2016-03-151-0/+109
|
* Versionbits testsPieter Wuille2016-03-151-0/+185