tests/acceptance: move @skipUnless decoration to test itself
PATCH 1/1 tests/acceptance: move @skipUnless decoration to test itself
It appears ignore the decoration if just applied to the class.
--- tests/acceptance/machine_mips_malta.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
tests/acceptance/machine_mips_malta.py +2 -2
@@ -30,14 +30,14 @@ except ImportError: CV2_AVAILABLE = False -@skipUnless(NUMPY_AVAILABLE, 'Python NumPy not installed') -@skipUnless(CV2_AVAILABLE, 'Python OpenCV not installed') class MaltaMachineFramebuffer(Test): timeout = 30 KERNEL_COMMON_COMMAND_LINE = 'printk.time=0 ' + @skipUnless(NUMPY_AVAILABLE, 'Python NumPy not installed') + @skipUnless(CV2_AVAILABLE, 'Python OpenCV not installed') def do_test_i6400_framebuffer_logo(self, cpu_cores_count): """ Boot Linux kernel and check Tux logo is displayed on the framebuffer.
Signature · 1 line
2.20.1
Quoted 1 line · Alex Bennée
It appears ignore the decoration if just applied to the class.
Odd I remember testing this, this might be a feature supported by a newer Avocado version than the one available on Travis-CI.
Quoted 18 lines
Signed-off-by Alex Bennée <[email protected]>--- tests/acceptance/machine_mips_malta.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)tests/acceptance/machine_mips_malta.py +0
-2@@ -30,14 +30,14 @@ except ImportError: CV2_AVAILABLE = False -@skipUnless(NUMPY_AVAILABLE, 'Python NumPy not installed') -@skipUnless(CV2_AVAILABLE, 'Python OpenCV not installed') class MaltaMachineFramebuffer(Test):
tests/acceptance/machine_mips_malta.py except ImportError: · line 43
Quoted 10 lines
tests/acceptance/machine_mips_malta.py +2
-0timeout = 30 KERNEL_COMMON_COMMAND_LINE = 'printk.time=0 ' + @skipUnless(NUMPY_AVAILABLE, 'Python NumPy not installed') + @skipUnless(CV2_AVAILABLE, 'Python OpenCV not installed') def do_test_i6400_framebuffer_logo(self, cpu_cores_count): """ Boot Linux kernel and check Tux logo is displayed on the framebuffer.
Unfortunately you have to also add it to the 7/8cores tests.
----- Original Message -----
Quoted 35 lines
From: "Philippe Mathieu-Daudé" <[email protected]>
To: "Alex Bennée" <[email protected]>, [email protected]
Cc: "Aurelien Jarno" <[email protected]>, [email protected], "Aleksandar Markovic" <[email protected]>
Sent: Monday, March 2, 2020 1:14:31 PM
Subject: Re: [PATCH] tests/acceptance: move @skipUnless decoration to test itselfQuoted 1 line · Alex Bennée
It appears ignore the decoration if just applied to the class.
Odd I remember testing this, this might be a feature supported by a newer Avocado version than the one available on Travis-CI.
Quoted 23 lines
Signed-off-by Alex Bennée <[email protected]>--- tests/acceptance/machine_mips_malta.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)tests/acceptance/machine_mips_malta.py +0
-2@@ -30,14 +30,14 @@ except ImportError: CV2_AVAILABLE = False -@skipUnless(NUMPY_AVAILABLE, 'Python NumPy not installed') -@skipUnless(CV2_AVAILABLE, 'Python OpenCV not installed') class MaltaMachineFramebuffer(Test): timeout = 30 KERNEL_COMMON_COMMAND_LINE = 'printk.time=0 '
Quoted 12 lines
Quoted 7 lines
tests/acceptance/machine_mips_malta.py +2
-0+ @skipUnless(NUMPY_AVAILABLE, 'Python NumPy not installed') + @skipUnless(CV2_AVAILABLE, 'Python OpenCV not installed') def do_test_i6400_framebuffer_logo(self, cpu_cores_count): """ Boot Linux kernel and check Tux logo is displayed on theframebuffer.
Unfortunately you have to also add it to the 7/8cores tests.
This is true of Avocado < 76.0, but on 76.0 you can decorate the class too:
https://avocado-framework.readthedocs.io/en/76.0/releases/76_0.html#users-test-writers
Maybe replace this patch and bump Avocado's version?
- Cleber.
Quoted 49 lines · Cleber Rosa
----- Original Message -----
Quoted 35 lines
From: "Philippe Mathieu-Daudé" <[email protected]>
To: "Alex Bennée" <[email protected]>, [email protected]
Cc: "Aurelien Jarno" <[email protected]>, [email protected], "Aleksandar Markovic" <[email protected]>
Sent: Monday, March 2, 2020 1:14:31 PM
Subject: Re: [PATCH] tests/acceptance: move @skipUnless decoration to test itselfQuoted 1 line · Alex Bennée
It appears ignore the decoration if just applied to the class.
Odd I remember testing this, this might be a feature supported by a newer Avocado version than the one available on Travis-CI.
Quoted 23 lines
Signed-off-by Alex Bennée <[email protected]>--- tests/acceptance/machine_mips_malta.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)tests/acceptance/machine_mips_malta.py +0
-2@@ -30,14 +30,14 @@ except ImportError: CV2_AVAILABLE = False -@skipUnless(NUMPY_AVAILABLE, 'Python NumPy not installed') -@skipUnless(CV2_AVAILABLE, 'Python OpenCV not installed') class MaltaMachineFramebuffer(Test): timeout = 30 KERNEL_COMMON_COMMAND_LINE = 'printk.time=0 'Quoted 12 lines
Quoted 7 lines
tests/acceptance/machine_mips_malta.py +2
-0+ @skipUnless(NUMPY_AVAILABLE, 'Python NumPy not installed') + @skipUnless(CV2_AVAILABLE, 'Python OpenCV not installed') def do_test_i6400_framebuffer_logo(self, cpu_cores_count): """ Boot Linux kernel and check Tux logo is displayed on theframebuffer.
Unfortunately you have to also add it to the 7/8cores tests.
Quoted 6 lines
This is true of Avocado < 76.0, but on 76.0 you can decorate the class too:
https://avocado-framework.readthedocs.io/en/76.0/releases/76_0.html#users-test-writers
Maybe replace this patch and bump Avocado's version?
Where is this defined in the source?
Quoted 2 lines
- Cleber.
Signature · 1 line
Alex Bennée
----- Original Message -----
Quoted 61 lines
From: "Alex Bennée" <[email protected]>
To: "Cleber Rosa" <[email protected]>
Cc: "Philippe Mathieu-Daudé" <[email protected]>, [email protected], "Aurelien Jarno" <[email protected]>, [email protected], "Aleksandar Markovic" <[email protected]>
Sent: Tuesday, March 3, 2020 8:59:47 AM
Subject: Re: [PATCH] tests/acceptance: move @skipUnless decoration to test itselfQuoted 51 lines · Cleber Rosa
----- Original Message -----
Quoted 49 lines
From: "Philippe Mathieu-Daudé" <[email protected]>
To: "Alex Bennée" <[email protected]>, [email protected]
Cc: "Aurelien Jarno" <[email protected]>, [email protected], "Aleksandar Markovic" <[email protected]>
Sent: Monday, March 2, 2020 1:14:31 PM
Subject: Re: [PATCH] tests/acceptance: move @skipUnless decoration to test itselfQuoted 1 line · Alex Bennée
It appears ignore the decoration if just applied to the class.
Odd I remember testing this, this might be a feature supported by a newer Avocado version than the one available on Travis-CI.
Quoted 28 lines
Signed-off-by Alex Bennée <[email protected]>--- tests/acceptance/machine_mips_malta.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)tests/acceptance/machine_mips_malta.py +2
-2@@ -30,14 +30,14 @@ except ImportError: CV2_AVAILABLE = False -@skipUnless(NUMPY_AVAILABLE, 'Python NumPy not installed') -@skipUnless(CV2_AVAILABLE, 'Python OpenCV not installed') class MaltaMachineFramebuffer(Test): timeout = 30 KERNEL_COMMON_COMMAND_LINE = 'printk.time=0 ' + @skipUnless(NUMPY_AVAILABLE, 'Python NumPy not installed') + @skipUnless(CV2_AVAILABLE, 'Python OpenCV not installed') def do_test_i6400_framebuffer_logo(self, cpu_cores_count): """ Boot Linux kernel and check Tux logo is displayed on theQuoted 2 lines
framebuffer.
Unfortunately you have to also add it to the 7/8cores tests.
Quoted 9 lines
Quoted 6 lines
This is true of Avocado < 76.0, but on 76.0 you can decorate the class too:
https://avocado-framework.readthedocs.io/en/76.0/releases/76_0.html#users-test-writers
Maybe replace this patch and bump Avocado's version?
Where is this defined in the source?
It's defined at tests/requirements.txt.
- Cleber.
Quoted 8 lines
Quoted 2 lines
- Cleber.
--
Alex Bennée