From 91d925ac9b1b301092f6afdb88cd1a74cf53d60d Mon Sep 17 00:00:00 2001 From: Kowshik Jois B S Date: Tue, 26 Mar 2024 20:15:22 +0530 Subject: [PATCH 1/5] Added package requirements for Ubuntu24 Signed-off-by: Kowshik Jois B S --- config/wrapper/env.conf | 2 ++ 1 file changed, 2 insertions(+) diff --git a/config/wrapper/env.conf b/config/wrapper/env.conf index 6b2be75..2fba631 100644 --- a/config/wrapper/env.conf +++ b/config/wrapper/env.conf @@ -40,6 +40,8 @@ packages = packages = [deps_ubuntu18_kvm] packages = p7zip,libvirt-dev,tcpdump,libosinfo-1.0-0,attr,libvirt-bin,arping,nfs-kernel-server,virtinst +[deps_ubuntu24] +packages = python3-dev,python3-setuptools,numactl,p7zip,libvirt-dev,tcpdump,libosinfo-1.0-0,libosinfo-bin,arping,nfs-kernel-server,virtinst [deps_rhel] packages = gcc,python3-devel,xz-devel,python3-setuptools,numactl,policycoreutils-python [deps_rhel_NV] From d647422265f05fd38819f2702f0c868d85362677 Mon Sep 17 00:00:00 2001 From: Kowshik Jois B S Date: Fri, 12 Apr 2024 18:12:21 +0530 Subject: [PATCH 2/5] Fix for pip issue with Ubuntu Signed-off-by: Kowshik Jois B S --- lib/helper.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/helper.py b/lib/helper.py index 0806183..6270d3d 100644 --- a/lib/helper.py +++ b/lib/helper.py @@ -243,14 +243,15 @@ def install(self): else: pip_installcmd = '%s install -U' % self.pip_cmd for package in self.install_packages: - cmd = '%s %s' % (pip_installcmd, package) + cmd = '%s %s --break-system-packages' % (pip_installcmd, package) runcmd(cmd, err_str='Package installation via pip failed: package %s' % package, debug_str='Installing python package %s using pip' % package) def uninstall(self): for package in self.uninstall_packages: - cmd = "%s uninstall %s -y --disable-pip-version-check" % (self.pip_cmd, package) + cmd = "%s uninstall %s --break-system-packages -y \ + --disable-pip-version-check" % (self.pip_cmd, package) runcmd(cmd, ignore_status=True, err_str="Error in removing package: %s" % package, debug_str="Uninstalling %s" % package) From a71daa25f023fc0cbc89d15d40b260ec0cd6ac90 Mon Sep 17 00:00:00 2001 From: Pavaman Subramaniyam Date: Tue, 16 Apr 2024 10:38:23 +0530 Subject: [PATCH 3/5] Update missing tests (#321) * Created the new network goodpath tests cfg file Also created the badpath scenario and vnic good path scenario files Signed-off-by: Pavaman Subramaniyam * Included the missing iperf and ethtool tests Updated the missing test script file and the corresponding yaml file in this cfg Signed-off-by: Pavaman Subramaniyam --------- Signed-off-by: Pavaman Subramaniyam --- .../host/io_network_scenario_badpath.cfg | 13 +++++++ .../host/io_network_scenario_goodpath.cfg | 18 ++++++++++ config/tests/host/io_roce_fvt.cfg | 2 ++ .../tests/host/io_vnic_scenario_goodpath.cfg | 35 +++++++++++++++++++ 4 files changed, 68 insertions(+) create mode 100644 config/tests/host/io_network_scenario_badpath.cfg create mode 100644 config/tests/host/io_network_scenario_goodpath.cfg create mode 100644 config/tests/host/io_vnic_scenario_goodpath.cfg diff --git a/config/tests/host/io_network_scenario_badpath.cfg b/config/tests/host/io_network_scenario_badpath.cfg new file mode 100644 index 0000000..2d50c79 --- /dev/null +++ b/config/tests/host/io_network_scenario_badpath.cfg @@ -0,0 +1,13 @@ +###### Network BadPath Scenario with HTX ####### +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_start avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/ras/sosreport.py avocado-misc-tests/ras/sosreport.py.data/options.yaml +avocado-misc-tests/ras/supportconfig.py +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/io/pci/pci_hotplug.py avocado-misc-tests/io/pci/pci_hotplug.py.data/pci_hotplug.yaml +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_stop avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + diff --git a/config/tests/host/io_network_scenario_goodpath.cfg b/config/tests/host/io_network_scenario_goodpath.cfg new file mode 100644 index 0000000..306203a --- /dev/null +++ b/config/tests/host/io_network_scenario_goodpath.cfg @@ -0,0 +1,18 @@ +###### Network GoodPath Scenario tests with HTX ####### +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_start avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/cpu/ppc64_cpu_test.py:PPC64Test.test_smt_loop +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/cpu/cpustress.py avocado-misc-tests/cpu/cpustress.py.data/cpustress.yaml +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/memory/memtester.py +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/io/net/bridge.py avocado-misc-tests/io/net/bridge.py.data/bridge.yaml +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_stop avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + diff --git a/config/tests/host/io_roce_fvt.cfg b/config/tests/host/io_roce_fvt.cfg index be0cb17..11f24de 100644 --- a/config/tests/host/io_roce_fvt.cfg +++ b/config/tests/host/io_roce_fvt.cfg @@ -35,10 +35,12 @@ avocado-misc-tests/io/net/multicast.py avocado-misc-tests/io/net/multicast.py.da avocado-misc-tests/io/net/multiport_stress.py avocado-misc-tests/io/net/multiport_stress.py.data/multiport_stress.yaml avocado-misc-tests/io/net/Network_config.py avocado-misc-tests/io/net/Network_config.py.data/Network_config.yaml avocado-misc-tests/io/net/uperf_test.py avocado-misc-tests/io/net/uperf_test.py.data/uperf_test.yaml +avocado-misc-tests/io/net/iperf_test.py avocado-misc-tests/io/net/iperf_test.py.data/iperf_test.yaml avocado-misc-tests/io/net/network_test.py avocado-misc-tests/io/net/network_test.py.data/network_test.yaml avocado-misc-tests/io/net/bridge.py avocado-misc-tests/io/net/bridge.py.data/bridge.yaml avocado-misc-tests/io/net/infiniband/dapl.py avocado-misc-tests/io/net/infiniband/dapl.py.data/dapl_roce.yaml avocado-misc-tests/io/net/bonding.py avocado-misc-tests/io/net/bonding.py.data/bonding.yaml "--execution-order tests-per-variant" +avocado-misc-tests/io/net/ethtool_test.py avocado-misc-tests/io/net/ethtool_test.py.data/ethtool_test.yaml avocado-misc-tests/io/net/htx_nic_devices.py avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml avocado-misc-tests/cpu/cpustress.py avocado-misc-tests/cpu/cpustress.py.data/cpustress.yaml avocado-misc-tests/memory/memtester.py avocado-misc-tests/memory/memtester.py.data/memtester.yaml diff --git a/config/tests/host/io_vnic_scenario_goodpath.cfg b/config/tests/host/io_vnic_scenario_goodpath.cfg new file mode 100644 index 0000000..22725ed --- /dev/null +++ b/config/tests/host/io_vnic_scenario_goodpath.cfg @@ -0,0 +1,35 @@ +avocado-misc-tests/io/net/virt-net/network_virtualization.py:NetworkVirtualization.test_add avocado-misc-tests/io/net/virt-net/network_virtualization.py.data/network_virtualization.yaml + +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_start avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/cpu/ppc64_cpu_test.py:PPC64Test.test_smt_loop +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/cpu/cpustress.py avocado-misc-tests/cpu/cpustress.py.data/cpustress.yaml +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/memory/memtester.py +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/io/net/bonding.py:Bonding.test_setup avocado-misc-tests/io/net/bonding.py.data/bonding_single.yaml +avocado-misc-tests/io/net/bonding.py:Bonding.test_run avocado-misc-tests/io/net/bonding.py.data/bonding_single.yaml +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/io/net/network_test.py:NetworkTest.test_gro avocado-misc-tests/io/net/network_test.py.data/network_test_virt_net.yaml +avocado-misc-tests/io/net/network_test.py:NetworkTest.test_lro avocado-misc-tests/io/net/network_test.py.data/network_test_virt_net.yaml +avocado-misc-tests/io/net/network_test.py:NetworkTest.test_tso avocado-misc-tests/io/net/network_test.py.data/network_test_virt_net.yaml +avocado-misc-tests/io/net/network_test.py:NetworkTest.test_promisc avocado-misc-tests/io/net/network_test.py.data/network_test_virt_net.yaml + +avocado-misc-tests/io/net/bonding.py:Bonding.test_cleanup avocado-misc-tests/io/net/bonding.py.data/bonding_single.yaml +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_stop avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_start avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/io/net/bridge.py avocado-misc-tests/io/net/bridge.py.data/bridge.yaml +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_check avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml + +avocado-misc-tests/io/net/htx_nic_devices.py:HtxNicTest.test_stop avocado-misc-tests/io/net/htx_nic_devices.py.data/htx_nic_devices.yaml +avocado-misc-tests/io/net/virt-net/network_virtualization.py:NetworkVirtualization.test_remove avocado-misc-tests/io/net/virt-net/network_virtualization.py.data/network_virtualization.yaml + From 02a3bd08d28f33c72f3cef3a3a37104df76bdd36 Mon Sep 17 00:00:00 2001 From: Misbah Anjum N Date: Tue, 16 Apr 2024 10:38:44 +0530 Subject: [PATCH 4/5] Update avocado-vt lifecycle.cfg to remove a test-case (#325) Removed Testcase: virsh.domstate.error_test.kill_vm.after_stopping_libvirtd The testcase stops libvirt and kills vm. After that, the entire bucket stops running. One has to manually add this line in .cfg file to run the lifecycle bucket every time. Signed-off-by: Misbah Anjum N --- config/tests/guest/libvirt/lifecycle.cfg | 2 ++ 1 file changed, 2 insertions(+) diff --git a/config/tests/guest/libvirt/lifecycle.cfg b/config/tests/guest/libvirt/lifecycle.cfg index 301112f..96da1a5 100644 --- a/config/tests/guest/libvirt/lifecycle.cfg +++ b/config/tests/guest/libvirt/lifecycle.cfg @@ -121,6 +121,8 @@ variants: # Only supported for libxl hypervisor driver no virsh.domstate.normal_test.reason.crash_vm.oncrash_rename_restart.restart_libvirtd no virsh.domstate.normal_test.reason.crash_vm.oncrash_rename_restart.normal + # Stops libvirt and kills VM, thus halting the test run + no virsh.domstate.error_test.kill_vm.after_stopping_libvirtd - domuuid: only virsh.domuuid - domxml: From 6c07671714ad91982e93a988ccef35bd4e39a49f Mon Sep 17 00:00:00 2001 From: Misbah Anjum N Date: Tue, 16 Apr 2024 10:41:54 +0530 Subject: [PATCH 5/5] analysis.py:Fix logical issue with DIFF, styling (#324) In comparison_analysis, the DIFF Result is generated even in case of new test-cases or removed test-cases where there will no test-case status This patch will fix this issue and give DIFF Result only when the test-case status are different Fixed inspekt styling errors given by command: inspekt style and inspekt indent on analysis.py Signed-off-by: Misbah Anjum N --- analysis.py | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) diff --git a/analysis.py b/analysis.py index bfe3418..6e2c455 100644 --- a/analysis.py +++ b/analysis.py @@ -16,10 +16,10 @@ ''' - analysis.py script is aimed to help in analysis/comparison of avocado test runs - by generating a simple excel file (.xlsx). The results.json file which gets created - after avocado run is passed as input in command line while running this script and - depending on the flag/options provided, the excel analysis/omparison sheet will be + analysis.py script is aimed to help in analysis/comparison of avocado test runs + by generating a simple excel file (.xlsx). The results.json file which gets created + after avocado run is passed as input in command line while running this script and + depending on the flag/options provided, the excel analysis/omparison sheet will be generated. Prerequsites:- @@ -77,10 +77,10 @@ def test_analysis(data): dataframe.to_excel('Analysis.xlsx', index=False) -def Comparison_Analysis(excel, data): +def comparison_analysis(excel, data): ''' This function is used to generate an excel sheet which gives delta comparison - of two test avocado based test runs. Using excel sheet produced from the + of two test avocado based test runs. Using excel sheet produced from the function: test_analysis(data) and results.json as inputs, it generate a .xlsx file as output. ''' @@ -136,6 +136,8 @@ def Comparison_Analysis(excel, data): results.append("REGRESSION") elif dataframe.loc[i].iat[-2] == "PASS" and not pd.isnull(dataframe.loc[i].iat[-4]): results.append("SOLVED") + elif pd.isnull(dataframe.loc[i].iat[-4]) or pd.isnull(dataframe.loc[i].iat[-2]): + results.append("") else: results.append("DIFF") @@ -216,7 +218,7 @@ def main(): with open(sys.argv[-1], 'r') as json_file: data = json.load(json_file) excel = sys.argv[-2] - Comparison_Analysis(excel, data) + comparison_analysis(excel, data) deco(excel) elif "--compare-two-results" in sys.argv: @@ -227,19 +229,20 @@ def main(): with open(sys.argv[-1], 'r') as json_file: data = json.load(json_file) - Comparison_Analysis("Analysis.xlsx", data) + comparison_analysis("Analysis.xlsx", data) deco("Analysis.xlsx") - + else: raise Exception - - except: + + except Exception as e: + print(str(e)) print("\nPay attention on the usage:\n"+usage()) sys.exit(1) def usage(): - return("python3 analysis.py --new-analysis \n\ + return ("python3 analysis.py --new-analysis \n\ python3 analysis.py --add-to-existing \n\ python3 analysis.py --compare-two-results \n")