mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-04-29 14:59:39 -04:00
test: -nodebug
clears previously set debug options
This commit is contained in:
parent
809d7e763c
commit
d39d521d86
1 changed files with 13 additions and 0 deletions
|
@ -99,6 +99,19 @@ class LoggingTest(BitcoinTestFramework):
|
||||||
match=ErrorMatch.PARTIAL_REGEX,
|
match=ErrorMatch.PARTIAL_REGEX,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
self.log.info("Test that -nodebug clears previously specified debug options")
|
||||||
|
disable_debug_options = [
|
||||||
|
'-nodebug'
|
||||||
|
]
|
||||||
|
|
||||||
|
for disable_debug_opt in disable_debug_options:
|
||||||
|
# Every category before disable_debug_opt will be ignored, including the invalid 'abc'
|
||||||
|
self.restart_node(0, ['-debug=http', '-debug=abc', disable_debug_opt, '-debug=rpc', '-debug=net'])
|
||||||
|
logging = self.nodes[0].logging()
|
||||||
|
assert not logging['http']
|
||||||
|
assert 'abc' not in logging
|
||||||
|
assert logging['rpc']
|
||||||
|
assert logging['net']
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
LoggingTest(__file__).main()
|
LoggingTest(__file__).main()
|
||||||
|
|
Loading…
Add table
Reference in a new issue