Page MenuHomePhabricator

[tests] Check connectivity before sending in assumevalid.py
ClosedPublic

Authored by deadalnix on Feb 24 2018, 06:35.

Details

Summary

assumevalid.py would try to send over a closed P2P connection in a loop,
hitting the following failure many times:

TestFramework.mininode (ERROR): Cannot send message. No connection to node!

The test still passes, but this is a lot of noise in the test log.

Just check that the connection is open before trying to send.

Backport core's PR11345

Test Plan
./test/functional/test_runner.py assumevalid.py

Diff Detail

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