Commit 3a7702f
committed
init: add pause_load_mempool test hook
A new -test=pause_load_mempool argument lets the test framework pause
node initialization right before loading the mempool. When set, the
node checks for the existence of a pause_load_mempool file and waits
until that file is removed.
Use this mechanism to test that savemempool fails before the mempool
is loaded, and that getmempoolinfo's "loaded" field is false.
Also add a test to ensure the pause can be interrupted.1 parent 5d7d4f0 commit 3a7702f
File tree
4 files changed
+39
-2
lines changed- src
- common
- test/functional
4 files changed
+39
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
769 | 769 | | |
770 | 770 | | |
771 | 771 | | |
| 772 | + | |
772 | 773 | | |
773 | 774 | | |
774 | 775 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
745 | 745 | | |
746 | 746 | | |
747 | 747 | | |
| 748 | + | |
| 749 | + | |
| 750 | + | |
| 751 | + | |
| 752 | + | |
| 753 | + | |
| 754 | + | |
| 755 | + | |
| 756 | + | |
| 757 | + | |
| 758 | + | |
748 | 759 | | |
749 | 760 | | |
750 | 761 | | |
| |||
2044 | 2055 | | |
2045 | 2056 | | |
2046 | 2057 | | |
| 2058 | + | |
2047 | 2059 | | |
2048 | 2060 | | |
2049 | 2061 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
292 | 292 | | |
293 | 293 | | |
294 | 294 | | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
295 | 310 | | |
296 | 311 | | |
297 | 312 | | |
298 | 313 | | |
299 | 314 | | |
300 | 315 | | |
| 316 | + | |
301 | 317 | | |
302 | 318 | | |
303 | 319 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
| 55 | + | |
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
| |||
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
117 | | - | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
118 | 126 | | |
119 | 127 | | |
120 | 128 | | |
| |||
0 commit comments