aboutsummaryrefslogtreecommitdiff
path: root/src/test
Commit message (Collapse)AuthorAgeFilesLines
* fix comments ExtractAddress() -> ExtractDestination()jtimon2014-08-281-2/+2
|
* Merge pull request #4377Pieter Wuille2014-08-271-5/+1
|\ | | | | | | | | | | 654871d replace ComputeMinWork with CheckMinWork (jtimon) b343c1a Move CBlockIndex::GetBlockWork() to pow::GetProofIncrement(nBits) (jtimon) c2c02f3 Move UpdateTime to pow (jtimon)
| * replace ComputeMinWork with CheckMinWorkjtimon2014-08-231-5/+1
| |
* | Merge pull request #4748Pieter Wuille2014-08-2611-29/+51
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ad49c25 Split up util.cpp/h (Wladimir J. van der Laan) f841aa2 Move `COIN` and `CENT` to core.h (Wladimir J. van der Laan) 6e5fd00 Move `*Version()` functions to version.h/cpp (Wladimir J. van der Laan) b4aa769 Move `S_I*` constants and `MSG_NOSIGNAL` to compat.h (Wladimir J. van der Laan) af8297c Move functions in wallet.h to implementation file (Wladimir J. van der Laan) 651480c move functions in main and net to implementation files (Wladimir J. van der Laan) 610a8c0 Move SetThreadPriority implementation to util.cpp instead of the header (Wladimir J. van der Laan) f780e65 Remove unused function `ByteReverse` from util.h (Wladimir J. van der Laan) 121d6ad Remove unused `alignup` function from util.h (Wladimir J. van der Laan) d1e26d4 Move CMedianFilter to timedata.cpp (Wladimir J. van der Laan)
| * | Split up util.cpp/hWladimir J. van der Laan2014-08-2610-4/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Split up util.cpp/h into: - string utilities (hex, base32, base64): no internal dependencies, no dependency on boost (apart from foreach) - money utilities (parsesmoney, formatmoney) - time utilities (gettime*, sleep, format date): - and the rest (logging, argument parsing, config file parsing) The latter is basically the environment and OS handling, and is stripped of all utility functions, so we may want to rename it to something else than util.cpp/h for clarity (Matt suggested osinterface). Breaks dependency of sha256.cpp on all the things pulled in by util.
| * | Move CMedianFilter to timedata.cppWladimir J. van der Laan2014-08-262-25/+38
| | | | | | | | | | | | | | | Now that we no longer use the median filter to keep track of the number of blocks of peers, that's the only place it is used.
* | | Test IsPushOnly() with invalid pushPeter Todd2014-08-241-0/+11
|/ /
* | Merge pull request #4618Pieter Wuille2014-08-241-1/+1
|\ \ | |/ |/| | | eb0b56b Simplify serialize.h's exception handling (Pieter Wuille)
| * Simplify serialize.h's exception handlingPieter Wuille2014-08-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove the 'state' and 'exceptmask' from serialize.h's stream implementations, as well as related methods. As exceptmask always included 'failbit', and setstate was always called with bits = failbit, all it did was immediately raise an exception. Get rid of those variables, and replace the setstate with direct exception throwing (which also removes some dead code). As a result, good() is never reached after a failure (there are only 2 calls, one of which is in tests), and can just be replaced by !eof(). fail(), clear(n) and exceptions() are just never called. Delete them.
* | Merge pull request #4733Jeff Garzik2014-08-227-3/+47
|\ \
| * | Add bitcoin-tx testsJeff Garzik2014-08-197-3/+47
| | | | | | | | | | | | | | | Testing: delin, delout, locktime, and basic createrawtransaction-like functionality.
* | | Merge pull request #4744Jeff Garzik2014-08-201-16/+16
|\ \ \
| * | | rpc_tests: use BOOST_CHECK_EQUALJeff Garzik2014-08-201-16/+16
| |/ / | | | | | | | | | | | | Upon failure, BOOST_CHECK_EQUAL provides additional diagnostic information, displaying that data that failed to match.
* | | UniValue tests: use more BOOST_CHECK()Jeff Garzik2014-08-201-20/+20
| | |
* | | UniValue: add unit testsJeff Garzik2014-08-201-0/+275
|/ /
* | bitcoin-tx: Accept input via stdin. Add input handling to tests.Jeff Garzik2014-08-192-2/+14
| |
* | Add "it works" test for bitcoin-txJeff Garzik2014-08-194-0/+53
| |
* | Declare SignatureHash() in script.hjtimon2014-08-014-9/+2
|/
* Merge pull request #4560Wladimir J. van der Laan2014-07-312-0/+10
|\ | | | | | | | | | | | | | | | | d2d9dc0 script tests: add tests for CHECKMULTISIG limits (Otto Allmendinger) 89101c6 script test: test case for 5-byte bools (Otto Allmendinger) 4cac5db script tests: value with trailing 0x00 is true (Otto Allmendinger) 833ff16 script tests: values that overflow to 0 are true (Otto Allmendinger) 0072d98 script tests: BOOLAND, BOOLOR decode to integer (Otto Allmendinger) ed02282 additional test for OP_SIZE in script_valid.json (Otto Allmendinger)
| * script tests: add tests for CHECKMULTISIG limitsOtto Allmendinger2014-07-181-0/+3
| |
| * script test: test case for 5-byte boolsOtto Allmendinger2014-07-181-0/+1
| |
| * script tests: value with trailing 0x00 is trueOtto Allmendinger2014-07-181-0/+1
| |
| * script tests: values that overflow to 0 are trueOtto Allmendinger2014-07-181-0/+1
| |
| * script tests: BOOLAND, BOOLOR decode to integerOtto Allmendinger2014-07-181-0/+3
| | | | | | | | unlike other boolean checks, arguments >5 bytes invalidate the script
| * additional test for OP_SIZE in script_valid.jsonOtto Allmendinger2014-07-181-0/+1
| |
* | Merge pull request #4568Wladimir J. van der Laan2014-07-311-0/+4
|\ \ | | | | | | | | | 9c34731 CBloomFilter::clear() method (Tom Harding)
| * | CBloomFilter::clear() methodTom Harding2014-07-211-0/+4
| | |
* | | Move ParseScript() helper, becoming accessible outside src/test/Jeff Garzik2014-07-292-71/+2
|/ /
* / Revert "CBloomFilter::clear() method"Wladimir J. van der Laan2014-07-211-4/+0
|/ | | | This reverts commit 8fbf03995df9a2003be603be1a930bc3373d56e0.
* move rand functions from util to new random.h/.cppPhilip Kaufmann2014-07-097-19/+19
|
* test/bloom_tests: Use UL suffix for unsigned long number to ensure compatibilityLuke Dashjr2014-07-071-1/+1
|
* Merge pull request #4045Wladimir J. van der Laan2014-07-071-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | a3e192a replaced MINE_ with ISMINE_ (JaSK) 53a2148 fixed bug where validateaddress doesn't display information (JaSK) f28707a fixed bug in ListReceived() (JaSK) 519dd1c Added MINE_ALL = (spendable|watchonly) (JaSK) 23b0506 Fixed some stuff in TransactionDesc (JaSK) 80dda36 removed default argument values for ismine filter (JaSK) d5087d1 Use script matching rather than destination matching for watch-only. (Pieter Wuille) 0fa2f88 added includedWatchonly argument to listreceivedbyaddress/...account (JaSK) f87ba3d added includeWatchonly argument to 'gettransaction' because it affects balance calculation (JaSK) a5c6c5d fixed tiny glitch and improved readability like laanwj suggested (JaSK) d7d5d23 Added argument to listtransactions and listsinceblock to include watchonly addresses (JaSK) 952877e Showing 'involvesWatchonly' property for transactions returned by 'listtransactions' and 'listsinceblock'. It is only appended when the transaction involves a watchonly address. (JaSK) 83f3543 Added argument to listaccounts to include watchonly addresses (JaSK) d4640d7 Added argument to getbalance to include watchonly addresses and fixed errors in balance calculation. (JaSK) d2692f6 Watchonly transactions are marked in transaction history (JaSK) ffd40da Watchonly balances are shown separately in gui. (JaSK) 2935b21 qt: Hide unspendable outputs in coin control (Wladimir J. van der Laan) c898846 Add support for watch-only addresses (Pieter Wuille)
| * Add support for watch-only addressesPieter Wuille2014-07-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * Add Add/Have WatchOnly methods to CKeyStore, and implementations in CBasicKeyStore. * Add similar methods to CWallet, and support entries for it in CWalletDB. * Make IsMine in script/wallet return a new enum 'isminetype', rather than a boolean. This allows distinguishing between spendable and unspendable coins. * Add a field fSpendable to COutput (GetAvailableCoins' return type). * Mark watchonly coins in listunspent as 'watchonly': true. * Add 'watchonly' to validateaddress, suppressing script/pubkey/... in this case. Based on a patch by Eric Lombrozo. Conflicts: src/qt/walletmodel.cpp src/rpcserver.cpp src/wallet.cpp
* | Merge pull request #4470Wladimir J. van der Laan2014-07-071-0/+56
|\ \ | | | | | | | | | | | | f4b00be Add CChain::GetLocator() unit test (Pieter Wuille) 3c85d2e Fix CChain::GetLocator (Pieter Wuille)
| * | Add CChain::GetLocator() unit testPieter Wuille2014-07-061-0/+56
| |/
* / Move ui_interface to bitcoin_server.aWladimir J. van der Laan2014-07-071-1/+1
|/ | | | | There is no need for it in the utility libraries or tools. Put it in init.cpp, and in the tests separately (as they can't link init).
* test: Fix warning about integer signedness in P2SH testsWladimir J. van der Laan2014-06-301-1/+1
|
* Merge pull request #3883 from dgenr8/first_double_spendGavin Andresen2014-06-301-0/+4
|\ | | | | Relay and alert user to double spends
| * CBloomFilter::clear() methodTom Harding2014-06-271-0/+4
| |
* | Add skiplist unit testsPieter Wuille2014-06-291-0/+45
|/
* Merge pull request #4365 from gavinandresen/relax_isstandardGavin Andresen2014-06-271-46/+72
|\ | | | | Relax IsStandard rules for pay-to-script-hash transactions
| * Relax IsStandard rules for pay-to-script-hash transactionsGavin Andresen2014-06-231-46/+72
| | | | | | | | | | | | | | | | | | | | | | Relax the AreInputsStandard() tests for P2SH transactions -- allow any Script in a P2SH transaction to be relayed/mined, as long as it has 15 or fewer signature operations. Rationale: https://gist.github.com/gavinandresen/88be40c141bc67acb247 I don't have an easy way to test this, but the code changes are straightforward and I've updated the AreInputsStandard unit tests.
* | Remove timing-based signature cache unit testGavin Andresen2014-06-251-87/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Two changes: First removes a unit test that fails in my development environment (OSX, compiled -g3 with clang). sipa says that's not terribly surprising; the CMutableTransaction change makes signing a little more expensive but verification quicker. The unit test timed sign+verify-uncached versus verify-cached-five-times. He also says the test will be invalid when libsec256kp1 is integrated (because validation is super-optimized over signing). core.h change fixes a compiler warning (clang -Wall : CMutableTransaction defined as struct, declared as class in script.h).
* | Remove unnecessary dependencies for bitcoin-cliWladimir J. van der Laan2014-06-252-6/+7
| | | | | | | | | | | | | | | | | | This commit removes all the unnecessary dependencies (key, core, netbase, sync, ...) from bitcoin-cli. To do this it shards the chain parameters into BaseParams, which contains just the RPC port and data directory (as used by utils and bitcoin-cli) and Params, with the rest.
* | Refactor proof of work related functions out of mainjtimon2014-06-231-0/+1
|/
* Code simplifications after CTransaction::GetHash() cachingPieter Wuille2014-06-221-13/+13
|
* Add CMutableTransaction and make CTransaction immutable.Pieter Wuille2014-06-2110-48/+60
| | | | | In addition, introduce a cached hash inside CTransaction, to prevent recalculating it over and over again.
* Add <Hasher>::OUTPUT_SIZEPieter Wuille2014-06-211-0/+1
|
* Extend and move all crypto tests to crypto_tests.cppPieter Wuille2014-06-213-184/+202
|
* Move crypto implementations to src/crypto/Pieter Wuille2014-06-212-2/+2
|