test suite reviews and discussions
 help / color / mirror / Atom feed
* [dts] [PATCH V1 0/1] tests/power_pbf: add one more check pattern
@ 2020-05-28  7:31 yufengmx
  2020-05-28  7:31 ` [dts] [PATCH V1 1/1] " yufengmx
  0 siblings, 1 reply; 3+ messages in thread
From: yufengmx @ 2020-05-28  7:31 UTC (permalink / raw)
  To: dts, lei.a.yao; +Cc: yufengmx

 add one more check pattern. 

yufengmx (1):
  tests/power_pbf: add one more check pattern

 tests/TestSuite_power_pbf.py | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

-- 
2.21.0


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

* [dts] [PATCH V1 1/1] tests/power_pbf: add one more check pattern
  2020-05-28  7:31 [dts] [PATCH V1 0/1] tests/power_pbf: add one more check pattern yufengmx
@ 2020-05-28  7:31 ` yufengmx
  2020-06-01  3:24   ` Tu, Lijuan
  0 siblings, 1 reply; 3+ messages in thread
From: yufengmx @ 2020-05-28  7:31 UTC (permalink / raw)
  To: dts, lei.a.yao; +Cc: yufengmx


:: add one more check pattern.

Signed-off-by: yufengmx <yufengx.mo@intel.com>
---
 tests/TestSuite_power_pbf.py | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/tests/TestSuite_power_pbf.py b/tests/TestSuite_power_pbf.py
index 0f312f5..8fcab51 100644
--- a/tests/TestSuite_power_pbf.py
+++ b/tests/TestSuite_power_pbf.py
@@ -367,6 +367,9 @@ class TestPowerPbf(TestCase):
         pat_begin = (
             'POWER: power_set_governor_performance: Power management '
             'governor of lcore (\\d+) is already performance')
+        pat_begin2 = (
+            'Power management governor of lcore (\d+) '
+            'has been set to performance successfully')
         pat_end = \
             'POWER: Initialized successfully for lcore (\\d+) power management'
         pat_freq = (
@@ -378,8 +381,12 @@ class TestPowerPbf(TestCase):
         for line in output.splitlines():
             # if core output begin message
             result = re.findall(pat_begin, line)
-            if result:
-                core_id = int(result[0])
+            result2 = re.findall(pat_begin2, line)
+            if result or result2:
+                if result:
+                    core_id = int(result[0])
+                elif result2:
+                    core_id = int(result2[0])
                 flag = True
             if flag:
                 result = re.findall(pat_freq, line)
-- 
2.21.0


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

* Re: [dts] [PATCH V1 1/1] tests/power_pbf: add one more check pattern
  2020-05-28  7:31 ` [dts] [PATCH V1 1/1] " yufengmx
@ 2020-06-01  3:24   ` Tu, Lijuan
  0 siblings, 0 replies; 3+ messages in thread
From: Tu, Lijuan @ 2020-06-01  3:24 UTC (permalink / raw)
  To: Mo, YufengX, dts, Yao, Lei A; +Cc: Mo, YufengX

Applied, thanks

> -----Original Message-----
> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of yufengmx
> Sent: Thursday, May 28, 2020 3:31 PM
> To: dts@dpdk.org; Yao, Lei A <lei.a.yao@intel.com>
> Cc: Mo, YufengX <yufengx.mo@intel.com>
> Subject: [dts] [PATCH V1 1/1] tests/power_pbf: add one more check pattern
> 
> 
> :: add one more check pattern.
> 
> Signed-off-by: yufengmx <yufengx.mo@intel.com>
> ---
>  tests/TestSuite_power_pbf.py | 11 +++++++++--
>  1 file changed, 9 insertions(+), 2 deletions(-)
> 
> diff --git a/tests/TestSuite_power_pbf.py b/tests/TestSuite_power_pbf.py
> index 0f312f5..8fcab51 100644
> --- a/tests/TestSuite_power_pbf.py
> +++ b/tests/TestSuite_power_pbf.py
> @@ -367,6 +367,9 @@ class TestPowerPbf(TestCase):
>          pat_begin = (
>              'POWER: power_set_governor_performance: Power management '
>              'governor of lcore (\\d+) is already performance')
> +        pat_begin2 = (
> +            'Power management governor of lcore (\d+) '
> +            'has been set to performance successfully')
>          pat_end = \
>              'POWER: Initialized successfully for lcore (\\d+) power management'
>          pat_freq = (
> @@ -378,8 +381,12 @@ class TestPowerPbf(TestCase):
>          for line in output.splitlines():
>              # if core output begin message
>              result = re.findall(pat_begin, line)
> -            if result:
> -                core_id = int(result[0])
> +            result2 = re.findall(pat_begin2, line)
> +            if result or result2:
> +                if result:
> +                    core_id = int(result[0])
> +                elif result2:
> +                    core_id = int(result2[0])
>                  flag = True
>              if flag:
>                  result = re.findall(pat_freq, line)
> --
> 2.21.0


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

end of thread, other threads:[~2020-06-01  3:24 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-28  7:31 [dts] [PATCH V1 0/1] tests/power_pbf: add one more check pattern yufengmx
2020-05-28  7:31 ` [dts] [PATCH V1 1/1] " yufengmx
2020-06-01  3:24   ` Tu, Lijuan

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