Page MenuHomePhabricator

test: feature_init: retain debug.log and improve detection
ClosedPublic

Authored by PiRK on Nov 25 2022, 09:27.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Commits
rABCb8b10db6522f: test: feature_init: retain debug.log and improve detection
Summary

test: introduce TestNode.debug_log_bytes

test: add TestNode.wait_for_debug_log

test: feature_init: retain debug.log and improve detection

This test sporadically fails due to the Python test missing log lines
for reasons that are poorly understood. The problem is made worse by the
fact that this test does not retain the log files from iteration to
iteration.

Change the test to do logline detection in a more robust manner (by
using re.search on the whole log content) in a way that is comparable
to the existing assert_debug_log utility, and retain all debug.log
content from case to case.

This is a partial backport of core#23737
https://github.com/bitcoin/bitcoin/pull/23737/commits/a2fb62b632d39e468f59e7e0b6890f82d0f5eebb
https://github.com/bitcoin/bitcoin/pull/23737/commits/a8ffbc01db85d918b8d1406b178b3c6f09123cf1
https://github.com/bitcoin/bitcoin/pull/23737/commits/93db6d8422345cc10db333d56ea9bcceefcf58b6

Depends on D12613

Test Plan

ninja check-functional

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable