Page MenuHomePhabricator

[tests] Better stderr testing
ClosedPublic

Authored by Fabien on Mon, Jun 10, 11:48.

Details

Reviewers
deadalnix
jasonbcox
Group Reviewers
Restricted Project
Maniphest Tasks
T540: Backport Core PR12755
Commits
rABC3263031e7f50: [tests] Better stderr testing
Summary
This PR tightens our checking of stderr and will cause tests to fail if
there is any unexpected message in stderr:

  - commit Write stdout/stderr to datadir instead of temp file writes
stderr to a file in the datadir instead of a temporary file. This helps
with debugging in the case of failure.
  - commit Use LIBC_FATAL_STDERR=1 in tests ensures that libc failures
are logged to stderr instead of the terminal.

Backport of core PR12755
https://github.com/bitcoin/bitcoin/pull/12755/files

Depends on D3273
Fixes T540

Test Plan
./test/functional/test_runner.py --extended

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Fabien created this revision.Mon, Jun 10, 11:48
Herald added a reviewer: Restricted Project. · View Herald TranscriptMon, Jun 10, 11:48
jasonbcox accepted this revision.Mon, Jun 10, 16:58
This revision is now accepted and ready to land.Mon, Jun 10, 16:58
This revision was automatically updated to reflect the committed changes.