From a431adf8676ea377175b91776082eb37d4773e80 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sun, 23 May 2021 11:46:04 +0200 Subject: smoketest: ethernet: bugfix RPS CPU validation We always read back the RPS value from eth1 which worked on the CI smoketests, but not when running a smoketest with only one interface e.g. by: $ TEST_ETH="eth2" /usr/libexec/vyos/tests/smoke/cli/test_interfaces_ethernet.py --- smoketest/scripts/cli/test_interfaces_ethernet.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'smoketest/scripts/cli/test_interfaces_ethernet.py') diff --git a/smoketest/scripts/cli/test_interfaces_ethernet.py b/smoketest/scripts/cli/test_interfaces_ethernet.py index cb0c8a426..a31d75423 100755 --- a/smoketest/scripts/cli/test_interfaces_ethernet.py +++ b/smoketest/scripts/cli/test_interfaces_ethernet.py @@ -118,7 +118,7 @@ class EthernetInterfaceTest(BasicInterfaceTest.TestCase): self.cli_commit() for interface in self._interfaces: - cpus = read_file('/sys/class/net/eth1/queues/rx-0/rps_cpus') + cpus = read_file(f'/sys/class/net/{interface}/queues/rx-0/rps_cpus') # remove the nasty ',' separation on larger strings cpus = cpus.replace(',','') cpus = int(cpus, 16) -- cgit v1.2.3