diff --git a/test/functional/feature_logging.py b/test/functional/feature_logging.py index ab817fd12d2..96b990c1d7a 100755 --- a/test/functional/feature_logging.py +++ b/test/functional/feature_logging.py @@ -99,6 +99,19 @@ class LoggingTest(BitcoinTestFramework): 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__': LoggingTest(__file__).main()