test suite reviews and discussions
 help / color / mirror / Atom feed
* [dts] [PATCH V1 0/1] tests/pmd_bonded_8023ad: update script by test plan change
@ 2020-05-15  5:52 yufengmx
  2020-05-15  5:52 ` [dts] [PATCH V1 1/1] " yufengmx
  2020-05-18  1:18 ` [dts] [PATCH V1 0/1] " Chen, Zhaoyan
  0 siblings, 2 replies; 5+ messages in thread
From: yufengmx @ 2020-05-15  5:52 UTC (permalink / raw)
  To: dts, zhaoyan.chen; +Cc: yufengmx

 update script by test plan change 

yufengmx (1):
  tests/pmd_bonded_8023ad: update script by test plan change

 tests/TestSuite_pmd_bonded_8023ad.py | 25 ++++++++++++++++++++++++-
 1 file changed, 24 insertions(+), 1 deletion(-)

-- 
2.21.0


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

* [dts] [PATCH V1 1/1] tests/pmd_bonded_8023ad: update script by test plan change
  2020-05-15  5:52 [dts] [PATCH V1 0/1] tests/pmd_bonded_8023ad: update script by test plan change yufengmx
@ 2020-05-15  5:52 ` yufengmx
  2020-05-18  1:18   ` Chen, Zhaoyan
  2020-05-19  2:00   ` Tu, Lijuan
  2020-05-18  1:18 ` [dts] [PATCH V1 0/1] " Chen, Zhaoyan
  1 sibling, 2 replies; 5+ messages in thread
From: yufengmx @ 2020-05-15  5:52 UTC (permalink / raw)
  To: dts, zhaoyan.chen; +Cc: yufengmx


update script by test plan change.

Signed-off-by: yufengmx <yufengx.mo@intel.com>
---
 tests/TestSuite_pmd_bonded_8023ad.py | 25 ++++++++++++++++++++++++-
 1 file changed, 24 insertions(+), 1 deletion(-)

diff --git a/tests/TestSuite_pmd_bonded_8023ad.py b/tests/TestSuite_pmd_bonded_8023ad.py
index 6267406..3707042 100644
--- a/tests/TestSuite_pmd_bonded_8023ad.py
+++ b/tests/TestSuite_pmd_bonded_8023ad.py
@@ -94,7 +94,30 @@ class TestBonding8023AD(TestCase):
             err_fmt = "link bonding mode 4 (802.3ad) set {0} failed"
             self.verify(expected_msg in out, err_fmt.format(status))
 
+    def set_special_command(self, bond_port):
+        cmds = [
+            "set bonding lacp dedicated_queues {} enable".format(bond_port),
+            "set allmulti 0 on",
+            "set allmulti 1 on",
+            "set allmulti {} on".format(bond_port),
+            "set portlist {}".format(bond_port), ]
+        [self.bond_inst.d_console([cmd, 'testpmd>', 15]) for cmd in cmds]
+
     def set_8023ad_bonded(self, slaves, bond_mode, ignore=True):
+        ''' set 802.3ad bonded mode for the specified bonding mode '''
+        specified_socket = self.dut.get_numa_id(slaves[0])
+        # create bonded device, add slaves in it
+        bond_port = self.bond_inst.create_bonded_device(bond_mode, specified_socket)
+        if not ignore:
+            # when no slave attached, mac should be 00:00:00:00:00:00
+            self.bonding_8023ad_check_macs_without_slaves(bond_port)
+        # add slave
+        self.bond_inst.add_slave(bond_port, False, '', *slaves)
+        # set special command
+        self.set_special_command(bond_port)
+        return bond_port
+
+    def set_8023ad_bonded2(self, slaves, bond_mode, ignore=True):
         ''' set 802.3ad bonded mode for the specified bonding mode '''
         specified_socket = self.dut.get_numa_id(slaves[0])
         # create bonded device, add slaves in it
@@ -332,7 +355,7 @@ class TestBonding8023AD(TestCase):
         for mode in self.DEDICATED_QUEUES:
             try:
                 self.bond_inst.start_testpmd()
-                bond_port = self.set_8023ad_bonded(slaves, bond_mode)
+                bond_port = self.set_8023ad_bonded2(slaves, bond_mode)
                 self.set_8023ad_dedicated_queues(bond_port, mode)
             except Exception as e:
                 check_results.append(e); print(traceback.format_exc())
-- 
2.21.0


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

* Re: [dts] [PATCH V1 1/1] tests/pmd_bonded_8023ad: update script by test plan change
  2020-05-15  5:52 ` [dts] [PATCH V1 1/1] " yufengmx
@ 2020-05-18  1:18   ` Chen, Zhaoyan
  2020-05-19  2:00   ` Tu, Lijuan
  1 sibling, 0 replies; 5+ messages in thread
From: Chen, Zhaoyan @ 2020-05-18  1:18 UTC (permalink / raw)
  To: Mo, YufengX, dts; +Cc: Chen, Zhaoyan

Acked-by: Zhaoyan Chen <zhaoyan.chen@intel.com>



Regards,
Zhaoyan Chen

> -----Original Message-----
> From: Mo, YufengX <yufengx.mo@intel.com>
> Sent: Friday, May 15, 2020 1:53 PM
> To: dts@dpdk.org; Chen, Zhaoyan <zhaoyan.chen@intel.com>
> Cc: Mo, YufengX <yufengx.mo@intel.com>
> Subject: [dts][PATCH V1 1/1] tests/pmd_bonded_8023ad: update script by
> test plan change
> 
> 
> update script by test plan change.
> 
> Signed-off-by: yufengmx <yufengx.mo@intel.com>
> ---
>  tests/TestSuite_pmd_bonded_8023ad.py | 25
> ++++++++++++++++++++++++-
>  1 file changed, 24 insertions(+), 1 deletion(-)
> 
> diff --git a/tests/TestSuite_pmd_bonded_8023ad.py
> b/tests/TestSuite_pmd_bonded_8023ad.py
> index 6267406..3707042 100644
> --- a/tests/TestSuite_pmd_bonded_8023ad.py
> +++ b/tests/TestSuite_pmd_bonded_8023ad.py
> @@ -94,7 +94,30 @@ class TestBonding8023AD(TestCase):
>              err_fmt = "link bonding mode 4 (802.3ad) set {0} failed"
>              self.verify(expected_msg in out, err_fmt.format(status))
> 
> +    def set_special_command(self, bond_port):
> +        cmds = [
> +            "set bonding lacp dedicated_queues {} enable".format(bond_port),
> +            "set allmulti 0 on",
> +            "set allmulti 1 on",
> +            "set allmulti {} on".format(bond_port),
> +            "set portlist {}".format(bond_port), ]
> +        [self.bond_inst.d_console([cmd, 'testpmd>', 15]) for cmd in
> + cmds]
> +
>      def set_8023ad_bonded(self, slaves, bond_mode, ignore=True):
> +        ''' set 802.3ad bonded mode for the specified bonding mode '''
> +        specified_socket = self.dut.get_numa_id(slaves[0])
> +        # create bonded device, add slaves in it
> +        bond_port = self.bond_inst.create_bonded_device(bond_mode,
> specified_socket)
> +        if not ignore:
> +            # when no slave attached, mac should be 00:00:00:00:00:00
> +            self.bonding_8023ad_check_macs_without_slaves(bond_port)
> +        # add slave
> +        self.bond_inst.add_slave(bond_port, False, '', *slaves)
> +        # set special command
> +        self.set_special_command(bond_port)
> +        return bond_port
> +
> +    def set_8023ad_bonded2(self, slaves, bond_mode, ignore=True):
>          ''' set 802.3ad bonded mode for the specified bonding mode '''
>          specified_socket = self.dut.get_numa_id(slaves[0])
>          # create bonded device, add slaves in it @@ -332,7 +355,7 @@ class
> TestBonding8023AD(TestCase):
>          for mode in self.DEDICATED_QUEUES:
>              try:
>                  self.bond_inst.start_testpmd()
> -                bond_port = self.set_8023ad_bonded(slaves, bond_mode)
> +                bond_port = self.set_8023ad_bonded2(slaves, bond_mode)
>                  self.set_8023ad_dedicated_queues(bond_port, mode)
>              except Exception as e:
>                  check_results.append(e); print(traceback.format_exc())
> --
> 2.21.0


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

* Re: [dts] [PATCH V1 0/1] tests/pmd_bonded_8023ad: update script by test plan change
  2020-05-15  5:52 [dts] [PATCH V1 0/1] tests/pmd_bonded_8023ad: update script by test plan change yufengmx
  2020-05-15  5:52 ` [dts] [PATCH V1 1/1] " yufengmx
@ 2020-05-18  1:18 ` Chen, Zhaoyan
  1 sibling, 0 replies; 5+ messages in thread
From: Chen, Zhaoyan @ 2020-05-18  1:18 UTC (permalink / raw)
  To: Mo, YufengX, dts; +Cc: Chen, Zhaoyan

Acked-by: Zhaoyan Chen <zhaoyan.chen@intel.com>



Regards,
Zhaoyan Chen

> -----Original Message-----
> From: Mo, YufengX <yufengx.mo@intel.com>
> Sent: Friday, May 15, 2020 1:53 PM
> To: dts@dpdk.org; Chen, Zhaoyan <zhaoyan.chen@intel.com>
> Cc: Mo, YufengX <yufengx.mo@intel.com>
> Subject: [dts][PATCH V1 0/1] tests/pmd_bonded_8023ad: update script by
> test plan change
> 
>  update script by test plan change
> 
> yufengmx (1):
>   tests/pmd_bonded_8023ad: update script by test plan change
> 
>  tests/TestSuite_pmd_bonded_8023ad.py | 25
> ++++++++++++++++++++++++-
>  1 file changed, 24 insertions(+), 1 deletion(-)
> 
> --
> 2.21.0


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

* Re: [dts] [PATCH V1 1/1] tests/pmd_bonded_8023ad: update script by test plan change
  2020-05-15  5:52 ` [dts] [PATCH V1 1/1] " yufengmx
  2020-05-18  1:18   ` Chen, Zhaoyan
@ 2020-05-19  2:00   ` Tu, Lijuan
  1 sibling, 0 replies; 5+ messages in thread
From: Tu, Lijuan @ 2020-05-19  2:00 UTC (permalink / raw)
  To: Mo, YufengX, dts, Chen, Zhaoyan; +Cc: Mo, YufengX

Applied, thanks

> -----Original Message-----
> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of yufengmx
> Sent: Friday, May 15, 2020 1:53 PM
> To: dts@dpdk.org; Chen, Zhaoyan <zhaoyan.chen@intel.com>
> Cc: Mo, YufengX <yufengx.mo@intel.com>
> Subject: [dts] [PATCH V1 1/1] tests/pmd_bonded_8023ad: update script by
> test plan change
> 
> 
> update script by test plan change.
> 
> Signed-off-by: yufengmx <yufengx.mo@intel.com>
> ---
>  tests/TestSuite_pmd_bonded_8023ad.py | 25 ++++++++++++++++++++++++-
>  1 file changed, 24 insertions(+), 1 deletion(-)
> 
> diff --git a/tests/TestSuite_pmd_bonded_8023ad.py
> b/tests/TestSuite_pmd_bonded_8023ad.py
> index 6267406..3707042 100644
> --- a/tests/TestSuite_pmd_bonded_8023ad.py
> +++ b/tests/TestSuite_pmd_bonded_8023ad.py
> @@ -94,7 +94,30 @@ class TestBonding8023AD(TestCase):
>              err_fmt = "link bonding mode 4 (802.3ad) set {0} failed"
>              self.verify(expected_msg in out, err_fmt.format(status))
> 
> +    def set_special_command(self, bond_port):
> +        cmds = [
> +            "set bonding lacp dedicated_queues {} enable".format(bond_port),
> +            "set allmulti 0 on",
> +            "set allmulti 1 on",
> +            "set allmulti {} on".format(bond_port),
> +            "set portlist {}".format(bond_port), ]
> +        [self.bond_inst.d_console([cmd, 'testpmd>', 15]) for cmd in
> + cmds]
> +
>      def set_8023ad_bonded(self, slaves, bond_mode, ignore=True):
> +        ''' set 802.3ad bonded mode for the specified bonding mode '''
> +        specified_socket = self.dut.get_numa_id(slaves[0])
> +        # create bonded device, add slaves in it
> +        bond_port = self.bond_inst.create_bonded_device(bond_mode,
> specified_socket)
> +        if not ignore:
> +            # when no slave attached, mac should be 00:00:00:00:00:00
> +            self.bonding_8023ad_check_macs_without_slaves(bond_port)
> +        # add slave
> +        self.bond_inst.add_slave(bond_port, False, '', *slaves)
> +        # set special command
> +        self.set_special_command(bond_port)
> +        return bond_port
> +
> +    def set_8023ad_bonded2(self, slaves, bond_mode, ignore=True):
>          ''' set 802.3ad bonded mode for the specified bonding mode '''
>          specified_socket = self.dut.get_numa_id(slaves[0])
>          # create bonded device, add slaves in it @@ -332,7 +355,7 @@ class
> TestBonding8023AD(TestCase):
>          for mode in self.DEDICATED_QUEUES:
>              try:
>                  self.bond_inst.start_testpmd()
> -                bond_port = self.set_8023ad_bonded(slaves, bond_mode)
> +                bond_port = self.set_8023ad_bonded2(slaves, bond_mode)
>                  self.set_8023ad_dedicated_queues(bond_port, mode)
>              except Exception as e:
>                  check_results.append(e); print(traceback.format_exc())
> --
> 2.21.0


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

end of thread, other threads:[~2020-05-19  2:00 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-15  5:52 [dts] [PATCH V1 0/1] tests/pmd_bonded_8023ad: update script by test plan change yufengmx
2020-05-15  5:52 ` [dts] [PATCH V1 1/1] " yufengmx
2020-05-18  1:18   ` Chen, Zhaoyan
2020-05-19  2:00   ` Tu, Lijuan
2020-05-18  1:18 ` [dts] [PATCH V1 0/1] " Chen, Zhaoyan

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).