Hodlinator
dbbb780af0
test: move and simplify BOOST_CHECK ostream helpers
...
Move the operator<< overloads used by BOOST_CHECK_* out of the
unit test machinery test/setup_common, into test/util/common.h.
And replace the individual per-type ToString() overloads with
a single concept-constrained template that covers any type
exposing a ToString() method. This is important to not add
uint256.h and transaction_identifier.h dependencies to the
shared test/util/common.h file.
Co-authored-by: furszy <matiasfurszyfer@protonmail.com >
2026-02-26 11:28:55 -03:00
MarcoFalke
fa5f297748
scripted-diff: [doc] Unify stale copyright headers
...
-BEGIN VERIFY SCRIPT-
sed --in-place --regexp-extended \
's;( 20[0-2][0-9])(-20[0-2][0-9])? The Bitcoin Core developers;\1-present The Bitcoin Core developers;g' \
$( git grep -l 'The Bitcoin Core developers' -- ':(exclude)COPYING' ':(exclude)src/ipc/libmultiprocess' ':(exclude)src/minisketch' )
-END VERIFY SCRIPT-
2025-12-16 22:21:15 +01:00
MarcoFalke
fa0fe08eca
scripted-diff: [test] Use g_rng/m_rng directly
...
-BEGIN VERIFY SCRIPT-
# Use m_rng in unit test files
ren() { sed -i "s:\<$1\>:$2:g" $( git grep -l "$1" src/test/*.cpp src/wallet/test/*.cpp src/test/util/setup_common.cpp ) ; }
ren InsecureRand32 m_rng.rand32
ren InsecureRand256 m_rng.rand256
ren InsecureRandBits m_rng.randbits
ren InsecureRandRange m_rng.randrange
ren InsecureRandBool m_rng.randbool
ren g_insecure_rand_ctx m_rng
ren g_insecure_rand_ctx_temp_path g_rng_temp_path
-END VERIFY SCRIPT-
2024-08-26 11:19:52 +02:00
Ryan Ofsky
3dc527f460
test: refactor: Give unit test functions access to test state
...
Add unit test subclasses as needed so unit test functions that need to access
members like m_rng can reference it directly.
2024-08-21 23:27:55 +02:00
Jon Atack
81f5ade2a3
Move random test util code from setup_common to random
...
as many of the unit tests don't use this code
2023-02-06 12:26:04 -08:00
Hennadii Stepanov
306ccd4927
scripted-diff: Bump copyright headers
...
-BEGIN VERIFY SCRIPT-
./contrib/devtools/copyright_header.py update ./
-END VERIFY SCRIPT-
Commits of previous years:
- 2021: f47dda2c58
- 2020: fa0074e2d8
- 2019: aaaaad6ac9
2022-12-24 23:49:50 +00:00
Hennadii Stepanov
97007e2b9b
test: Prevent UB in minisketch_tests.cpp
2022-10-06 12:50:54 +01:00
Russell Yanofsky
90fc8b089d
Add src/node/* code to node:: namespace
2022-01-06 22:14:16 -05:00
MarcoFalke
fa8f60e311
scripted-diff: Move minisketchwrapper to src/node
...
-BEGIN VERIFY SCRIPT-
# Move module
git mv src/minisketchwrapper.cpp src/node/
git mv src/minisketchwrapper.h src/node/
# Replacements
sed -i 's:minisketchwrapper:node/minisketchwrapper:g' $(git grep -l minisketchwrapper)
sed -i 's:MINISKETCHWRAPPER_H:NODE_MINISKETCHWRAPPER_H:g' $(git grep -l MINISKETCHWRAPPER_H)
sed -i 's:DBWRAPPER_H:NODE_MINISKETCHWRAPPER_H:g' ./src/node/minisketchwrapper.h
-END VERIFY SCRIPT-
2021-11-12 10:56:08 +01:00
Pieter Wuille
54b5e1aeab
Add thin Minisketch wrapper to pick best implementation
2021-10-21 09:39:16 +08:00
Pieter Wuille
ee9dc71c1b
Add basic minisketch tests
2021-10-21 09:39:04 +08:00