<div dir="ltr">Actually, would you want to use logger to print a "hello world" message. It might make the testsuite name make more sense hah.</div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Mon, Jan 6, 2025 at 11:57 AM Dean Marx <<a href="mailto:dmarx@iol.unh.edu">dmarx@iol.unh.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Add a test suite to replace hello_world which simply<br>
starts and stops a testpmd session. The user can use<br>
this as a confidence check to verify their configuration.<br>
<br>
Signed-off-by: Dean Marx <<a href="mailto:dmarx@iol.unh.edu" target="_blank">dmarx@iol.unh.edu</a>><br>
Reviewed-by: Paul Szczepanek <<a href="mailto:paul.szczepanek@arm.com" target="_blank">paul.szczepanek@arm.com</a>><br>
---<br>
 dts/tests/TestSuite_hello_world.py | 68 ++++++------------------------<br>
 1 file changed, 12 insertions(+), 56 deletions(-)<br>
<br>
diff --git a/dts/tests/TestSuite_hello_world.py b/dts/tests/TestSuite_hello_world.py<br>
index 734f006026..75f168bc9f 100644<br>
--- a/dts/tests/TestSuite_hello_world.py<br>
+++ b/dts/tests/TestSuite_hello_world.py<br>
@@ -1,71 +1,27 @@<br>
 # SPDX-License-Identifier: BSD-3-Clause<br>
-# Copyright(c) 2010-2014 Intel Corporation<br>
+# Copyright(c) 2024 University of New Hampshire<br>
<br>
-"""The DPDK hello world app test suite.<br>
+"""DPDK Hello World test suite.<br>
<br>
-Run the helloworld example app and verify it prints a message for each used core.<br>
-No other EAL parameters apart from cores are used.<br>
+Starts and stops a testpmd session to verify EAL parameters<br>
+are properly configured.<br>
 """<br>
<br>
-from framework.remote_session.dpdk_shell import compute_eal_params<br>
+from framework.remote_session.testpmd_shell import TestPmdShell<br>
 from framework.test_suite import TestSuite, func_test<br>
-from framework.testbed_model.capability import TopologyType, requires<br>
-from framework.testbed_model.cpu import (<br>
-    LogicalCoreCount,<br>
-    LogicalCoreCountFilter,<br>
-    LogicalCoreList,<br>
-)<br>
<br>
<br>
-@requires(topology_type=TopologyType.no_link)<br>
 class TestHelloWorld(TestSuite):<br>
-    """DPDK hello world app test suite."""<br>
-<br>
-    def set_up_suite(self) -> None:<br>
-        """Set up the test suite.<br>
-<br>
-        Setup:<br>
-            Build the app we're about to test - helloworld.<br>
-        """<br>
-        self.app_helloworld_path = self.sut_node.build_dpdk_app("helloworld")<br>
-<br>
-    @func_test<br>
-    def hello_world_single_core(self) -> None:<br>
-        """Single core test case.<br>
-<br>
-        Steps:<br>
-            Run the helloworld app on the first usable logical core.<br>
-        Verify:<br>
-            The app prints a message from the used core:<br>
-            "hello from core <core_id>"<br>
-        """<br>
-        # get the first usable core<br>
-        lcore_amount = LogicalCoreCount(1, 1, 1)<br>
-        lcores = LogicalCoreCountFilter(self.sut_node.lcores, lcore_amount).filter()<br>
-        eal_para = compute_eal_params(self.sut_node, lcore_filter_specifier=lcore_amount)<br>
-        result = self.sut_node.run_dpdk_app(self.app_helloworld_path, eal_para)<br>
-        self.verify(<br>
-            f"hello from core {int(lcores[0])}" in result.stdout,<br>
-            f"helloworld didn't start on lcore{lcores[0]}",<br>
-        )<br>
+    """Hello World test suite. One test case, which starts and stops a testpmd session."""<br>
<br>
     @func_test<br>
-    def hello_world_all_cores(self) -> None:<br>
-        """All cores test case.<br>
+    def test_hello_world(self) -> None:<br>
+        """EAL confidence test.<br>
<br>
         Steps:<br>
-            Run the helloworld app on all usable logical cores.<br>
+            Start testpmd session and check status.<br>
         Verify:<br>
-            The app prints a message from all used cores:<br>
-            "hello from core <core_id>"<br>
+            The testpmd session throws no errors.<br>
         """<br>
-        # get the maximum logical core number<br>
-        eal_para = compute_eal_params(<br>
-            self.sut_node, lcore_filter_specifier=LogicalCoreList(self.sut_node.lcores)<br>
-        )<br>
-        result = self.sut_node.run_dpdk_app(self.app_helloworld_path, eal_para, 50)<br>
-        for lcore in self.sut_node.lcores:<br>
-            self.verify(<br>
-                f"hello from core {int(lcore)}" in result.stdout,<br>
-                f"helloworld didn't start on lcore{lcore}",<br>
-            )<br>
+        with TestPmdShell(node=self.sut_node) as testpmd:<br>
+            testpmd.start()<br>
-- <br>
2.44.0<br>
<br>
</blockquote></div>