From e7af7457970ff32711a1073a584dccbc82a0ecc4 Mon Sep 17 00:00:00 2001 From: Christian Breunig Date: Sat, 15 Mar 2025 21:31:49 +0100 Subject: smoketest: T7248: ensure there is no Yacc/Bison error in wide-dhcpv6-client T7050 revealed an issue in the CI system where VyOS CLI was rendering a configuration for wide-dhcpv6-client that was not working due to a missing patch of the wide-dhcpv6-client source code. This can be prevented by checking the daemon logs after startup for any config linguistic (Yacc/Bison) issues. --- smoketest/scripts/cli/base_interfaces_test.py | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'smoketest') diff --git a/smoketest/scripts/cli/base_interfaces_test.py b/smoketest/scripts/cli/base_interfaces_test.py index c5a5bfac0..80d200e97 100644 --- a/smoketest/scripts/cli/base_interfaces_test.py +++ b/smoketest/scripts/cli/base_interfaces_test.py @@ -17,6 +17,7 @@ import re from netifaces import AF_INET from netifaces import AF_INET6 from netifaces import ifaddresses +from systemd import journal from base_vyostest_shim import VyOSUnitTestSHIM from base_vyostest_shim import CSTORE_GUARD_TIME @@ -1151,10 +1152,19 @@ class BasicInterfaceTest: self.assertIn('};', dhcpc6_config) duid_base += 1 + # T7058: verify daemon has no problems understanding the custom DUID option + j = journal.Reader() + j.this_boot() + j.add_match(_SYSTEMD_UNIT=f'dhcp6c@{interface}.service') + for entry in j: + self.assertNotIn('yyerror0', entry.get('MESSAGE', '')) + self.assertNotIn('syntax error', entry.get('MESSAGE', '')) + # Better ask the process about it's commandline in the future pid = process_named_running(dhcp6c_process_name, cmdline=interface, timeout=10) self.assertTrue(pid) + # DHCPv6 option "no-release" requires "-n" daemon startup option dhcp6c_options = read_file(f'/proc/{pid}/cmdline') self.assertIn('-n', dhcp6c_options) -- cgit v1.2.3