From: Yu Watanabe Date: Sat, 18 Dec 2021 00:55:54 +0000 (+0900) Subject: test-network: introduce dump_dnsmasq_log_file() X-Git-Tag: v250-rc3~16^2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2616b5285fd209c867e028a60e8ab9bfc4fb19b4;p=thirdparty%2Fsystemd.git test-network: introduce dump_dnsmasq_log_file() --- diff --git a/test/test-network/systemd-networkd-tests.py b/test/test-network/systemd-networkd-tests.py index 009ab706990..28a54dc4f75 100755 --- a/test/test-network/systemd-networkd-tests.py +++ b/test/test-network/systemd-networkd-tests.py @@ -526,6 +526,11 @@ def stop_by_pid_file(pid_file): def stop_dnsmasq(): stop_by_pid_file(dnsmasq_pid_file) +def dump_dnsmasq_log_file(): + if os.path.exists(dnsmasq_log_file): + with open (dnsmasq_log_file) as in_file: + print(in_file.read()) + def search_words_in_dnsmasq_log(words, show_all=False): if os.path.exists(dnsmasq_log_file): with open (dnsmasq_log_file) as in_file: