test suite reviews and discussions
 help / color / mirror / Atom feed
* [dts] [PATCH V1 1/2] tests/cbdma: modify testsuite sync with dpdk change
@ 2021-11-05  7:58 Wei Ling
  2021-11-05 14:34 ` Tu, Lijuan
  0 siblings, 1 reply; 3+ messages in thread
From: Wei Ling @ 2021-11-05  7:58 UTC (permalink / raw)
  To: dts; +Cc: Wei Ling

1.According to the dpdk-21.11-rc1 'd047310407a3511b1e2910c7ddf59d5049b202f6'
change from example/ioat to /example/dma, dts need to change sync with
dpdk.

2.The print info format have been changed, so need to modify check
point.

3.Improve checkpoints according to test plan.

Signed-off-by: Wei Ling <weix.ling@intel.com>
---
 tests/TestSuite_cbdma.py | 22 ++++++++++------------
 1 file changed, 10 insertions(+), 12 deletions(-)

diff --git a/tests/TestSuite_cbdma.py b/tests/TestSuite_cbdma.py
index dd1e4e44..3a70f176 100644
--- a/tests/TestSuite_cbdma.py
+++ b/tests/TestSuite_cbdma.py
@@ -60,8 +60,8 @@ class TestCBDMA(TestCase):
         self.cbdma_proc = '--proc-type=primary'
         # default v_dev is None, case 1-6 use default None values, case7 use --vdev net_null_0
         self.v_dev = ''
-        out = self.dut.build_dpdk_apps('./examples/ioat')
-        self.ioat_path = self.dut.apps_name['ioat']
+        out = self.dut.build_dpdk_apps('./examples/dma')
+        self.ioat_path = self.dut.apps_name['dma']
         self.verify('Error' not in out, 'compilation ioat error')
 
     def set_up(self):
@@ -92,10 +92,8 @@ class TestCBDMA(TestCase):
         get all cbdma ports
         """
         # check driver name in execution.cfg
-        self.verify(self.drivername == 'igb_uio',
-                    "CBDMA test case only use igb_uio driver, need config drivername=igb_uio in execution.cfg")
         str_info = 'Misc (rawdev) devices using kernel driver'
-        out = self.dut.send_expect('./usertools/dpdk-devbind.py --status-dev misc', '# ', 30)
+        out = self.dut.send_expect('./usertools/dpdk-devbind.py --status-dev dma', '# ', 30)
         device_info = out.split('\n')
         for device in device_info:
             pci_info = re.search('\s*(0000:\d*:\d*.\d*)', device)
@@ -220,9 +218,9 @@ class TestCBDMA(TestCase):
         out = self.send_session.get_session_before(timeout=2)
         index = out.rfind('Statistics for port 0')
         out = out[index:]
-        data_info = re.findall('successful_enqueues:\s*(\d*)', out)
-        self.verify(len(data_info) == self.cbdma_ioat_dev_num, 'There miss some queue, the run queue is '
-                    '%d, and expect queue num is %d' % (len(data_info), self.cbdma_ioat_dev_num))
+        data_info = re.findall('Total completed ops:\s*(\d*)', out)
+        self.verify((len(data_info) - 1) == self.cbdma_ioat_dev_num, 'There miss some queue, the run queue is '
+                    '%d, and expect queue num is %d' % ((len(data_info) - 1), self.cbdma_ioat_dev_num))
         for index in range(self.cbdma_ioat_dev_num):
             self.verify(data_info[index] != 0, 'the queue %d can not enqueues data' % index)
 
@@ -254,7 +252,7 @@ class TestCBDMA(TestCase):
         dev_info = self.get_ports_info()
         eal_params = self.dut.create_eal_parameters(cores=self.core_list, ports=dev_info, prefix='cbdma')
         self.launch_ioatfwd_app(eal_params)
-        self.send_and_verify_throughput(check_channel=False)
+        self.send_and_verify_throughput(check_channel=True)
         self.result_table_print()
 
     def test_perf_cbdma_with_multi_thread(self):
@@ -271,7 +269,7 @@ class TestCBDMA(TestCase):
         dev_info = self.get_ports_info()
         eal_params = self.dut.create_eal_parameters(cores=self.core_list, ports=dev_info, prefix='cbdma')
         self.launch_ioatfwd_app(eal_params)
-        self.send_and_verify_throughput(check_channel=False)
+        self.send_and_verify_throughput(check_channel=True)
         self.result_table_print()
 
     def test_perf_cbdma_with_multi_nic_ports(self):
@@ -325,11 +323,11 @@ class TestCBDMA(TestCase):
         dev_info = self.get_ports_info()
         eal_params = self.dut.create_eal_parameters(cores=self.core_list, ports=dev_info, prefix='cbdma')
         self.launch_ioatfwd_app(eal_params)
-        self.send_and_verify_throughput(check_channel=False)
+        self.send_and_verify_throughput(check_channel=True)
         self.send_session.send_expect('^c', '# ')
         self.cbdma_updating_mac = 'disable'
         self.launch_ioatfwd_app(eal_params)
-        self.send_and_verify_throughput(check_channel=False)
+        self.send_and_verify_throughput(check_channel=True)
         self.result_table_print()
 
     def test_perf_cbdma_with_diff_copy_mode(self):
-- 
2.25.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [dts] [PATCH V1 1/2] tests/cbdma: modify testsuite sync with dpdk change
  2021-11-05  7:58 [dts] [PATCH V1 1/2] tests/cbdma: modify testsuite sync with dpdk change Wei Ling
@ 2021-11-05 14:34 ` Tu, Lijuan
  0 siblings, 0 replies; 3+ messages in thread
From: Tu, Lijuan @ 2021-11-05 14:34 UTC (permalink / raw)
  To: Ling, WeiX, dts; +Cc: Ling, WeiX

> -----Original Message-----
> From: dts <dts-bounces@dpdk.org> On Behalf Of Wei Ling
> Sent: 2021年11月5日 15:58
> To: dts@dpdk.org
> Cc: Ling, WeiX <weix.ling@intel.com>
> Subject: [dts] [PATCH V1 1/2] tests/cbdma: modify testsuite sync with dpdk
> change
> 
> 1.According to the dpdk-21.11-rc1
> 'd047310407a3511b1e2910c7ddf59d5049b202f6'
> change from example/ioat to /example/dma, dts need to change sync with dpdk.
> 
> 2.The print info format have been changed, so need to modify check point.
> 
> 3.Improve checkpoints according to test plan.
> 
> Signed-off-by: Wei Ling <weix.ling@intel.com>

All related test suites and test plans should be modified to accommodate to dpdk, not only test suite cdma.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [dts] [PATCH V1 1/2] tests/cbdma: modify testsuite sync with dpdk change
@ 2021-11-05  7:50 Wei Ling
  0 siblings, 0 replies; 3+ messages in thread
From: Wei Ling @ 2021-11-05  7:50 UTC (permalink / raw)
  To: dts; +Cc: Wei Ling

1.According to the dpdk-21.11-rc1 'd047310407a3511b1e2910c7ddf59d5049b202f6'
change from example/ioat to /example/dma, dts need to change sync with
dpdk.

2.The print info format have been changed, so need to modify check
point.

3.Improve checkpoints according to test plan.

Signed-off-by: Wei Ling <weix.ling@intel.com>
---
 tests/TestSuite_cbdma.py | 22 ++++++++++------------
 1 file changed, 10 insertions(+), 12 deletions(-)

diff --git a/tests/TestSuite_cbdma.py b/tests/TestSuite_cbdma.py
index dd1e4e44..3a70f176 100644
--- a/tests/TestSuite_cbdma.py
+++ b/tests/TestSuite_cbdma.py
@@ -60,8 +60,8 @@ class TestCBDMA(TestCase):
         self.cbdma_proc = '--proc-type=primary'
         # default v_dev is None, case 1-6 use default None values, case7 use --vdev net_null_0
         self.v_dev = ''
-        out = self.dut.build_dpdk_apps('./examples/ioat')
-        self.ioat_path = self.dut.apps_name['ioat']
+        out = self.dut.build_dpdk_apps('./examples/dma')
+        self.ioat_path = self.dut.apps_name['dma']
         self.verify('Error' not in out, 'compilation ioat error')
 
     def set_up(self):
@@ -92,10 +92,8 @@ class TestCBDMA(TestCase):
         get all cbdma ports
         """
         # check driver name in execution.cfg
-        self.verify(self.drivername == 'igb_uio',
-                    "CBDMA test case only use igb_uio driver, need config drivername=igb_uio in execution.cfg")
         str_info = 'Misc (rawdev) devices using kernel driver'
-        out = self.dut.send_expect('./usertools/dpdk-devbind.py --status-dev misc', '# ', 30)
+        out = self.dut.send_expect('./usertools/dpdk-devbind.py --status-dev dma', '# ', 30)
         device_info = out.split('\n')
         for device in device_info:
             pci_info = re.search('\s*(0000:\d*:\d*.\d*)', device)
@@ -220,9 +218,9 @@ class TestCBDMA(TestCase):
         out = self.send_session.get_session_before(timeout=2)
         index = out.rfind('Statistics for port 0')
         out = out[index:]
-        data_info = re.findall('successful_enqueues:\s*(\d*)', out)
-        self.verify(len(data_info) == self.cbdma_ioat_dev_num, 'There miss some queue, the run queue is '
-                    '%d, and expect queue num is %d' % (len(data_info), self.cbdma_ioat_dev_num))
+        data_info = re.findall('Total completed ops:\s*(\d*)', out)
+        self.verify((len(data_info) - 1) == self.cbdma_ioat_dev_num, 'There miss some queue, the run queue is '
+                    '%d, and expect queue num is %d' % ((len(data_info) - 1), self.cbdma_ioat_dev_num))
         for index in range(self.cbdma_ioat_dev_num):
             self.verify(data_info[index] != 0, 'the queue %d can not enqueues data' % index)
 
@@ -254,7 +252,7 @@ class TestCBDMA(TestCase):
         dev_info = self.get_ports_info()
         eal_params = self.dut.create_eal_parameters(cores=self.core_list, ports=dev_info, prefix='cbdma')
         self.launch_ioatfwd_app(eal_params)
-        self.send_and_verify_throughput(check_channel=False)
+        self.send_and_verify_throughput(check_channel=True)
         self.result_table_print()
 
     def test_perf_cbdma_with_multi_thread(self):
@@ -271,7 +269,7 @@ class TestCBDMA(TestCase):
         dev_info = self.get_ports_info()
         eal_params = self.dut.create_eal_parameters(cores=self.core_list, ports=dev_info, prefix='cbdma')
         self.launch_ioatfwd_app(eal_params)
-        self.send_and_verify_throughput(check_channel=False)
+        self.send_and_verify_throughput(check_channel=True)
         self.result_table_print()
 
     def test_perf_cbdma_with_multi_nic_ports(self):
@@ -325,11 +323,11 @@ class TestCBDMA(TestCase):
         dev_info = self.get_ports_info()
         eal_params = self.dut.create_eal_parameters(cores=self.core_list, ports=dev_info, prefix='cbdma')
         self.launch_ioatfwd_app(eal_params)
-        self.send_and_verify_throughput(check_channel=False)
+        self.send_and_verify_throughput(check_channel=True)
         self.send_session.send_expect('^c', '# ')
         self.cbdma_updating_mac = 'disable'
         self.launch_ioatfwd_app(eal_params)
-        self.send_and_verify_throughput(check_channel=False)
+        self.send_and_verify_throughput(check_channel=True)
         self.result_table_print()
 
     def test_perf_cbdma_with_diff_copy_mode(self):
-- 
2.25.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-11-05 14:34 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-05  7:58 [dts] [PATCH V1 1/2] tests/cbdma: modify testsuite sync with dpdk change Wei Ling
2021-11-05 14:34 ` Tu, Lijuan
  -- strict thread matches above, loose matches on Subject: below --
2021-11-05  7:50 Wei Ling

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).