[OE-core] [PATCH 2/2] oeqa/runtime: Added skipModule import for test modules that use it.

Paul Eggleton paul.eggleton at linux.intel.com
Fri Jul 25 16:16:26 UTC 2014


On Thursday 24 July 2014 15:41:25 Lucian Musat wrote:
> The modules that use skipModule should import it themselves and not rely on
> somebody else to import it.
> 
> Signed-off-by: Lucian Musat <georgex.l.musat at intel.com>
> ---
>  meta/lib/oeqa/runtime/buildcvs.py      | 2 +-
>  meta/lib/oeqa/runtime/buildiptables.py | 2 +-
>  meta/lib/oeqa/runtime/buildsudoku.py   | 2 +-
>  meta/lib/oeqa/runtime/ldd.py           | 2 +-
>  meta/lib/oeqa/runtime/pam.py           | 8 ++++----
>  meta/lib/oeqa/runtime/skeletoninit.py  | 2 +-
>  meta/lib/oeqa/runtime/smart.py         | 2 +-
>  meta/lib/oeqa/runtime/vnc.py           | 2 +-
>  8 files changed, 11 insertions(+), 11 deletions(-)
> 
> diff --git a/meta/lib/oeqa/runtime/buildcvs.py
> b/meta/lib/oeqa/runtime/buildcvs.py index f1fbf19..6201ed1 100644
> --- a/meta/lib/oeqa/runtime/buildcvs.py
> +++ b/meta/lib/oeqa/runtime/buildcvs.py
> @@ -1,4 +1,4 @@
> -from oeqa.oetest import oeRuntimeTest
> +from oeqa.oetest import oeRuntimeTest, skipModule
>  from oeqa.utils.decorators import *
>  from oeqa.utils.targetbuild import TargetBuildProject
> 
> diff --git a/meta/lib/oeqa/runtime/buildiptables.py
> b/meta/lib/oeqa/runtime/buildiptables.py index f6061a7..c77b114 100644
> --- a/meta/lib/oeqa/runtime/buildiptables.py
> +++ b/meta/lib/oeqa/runtime/buildiptables.py
> @@ -1,4 +1,4 @@
> -from oeqa.oetest import oeRuntimeTest
> +from oeqa.oetest import oeRuntimeTest, skipModule
>  from oeqa.utils.decorators import *
>  from oeqa.utils.targetbuild import TargetBuildProject
> 
> diff --git a/meta/lib/oeqa/runtime/buildsudoku.py
> b/meta/lib/oeqa/runtime/buildsudoku.py index a754f1d..f51af92 100644
> --- a/meta/lib/oeqa/runtime/buildsudoku.py
> +++ b/meta/lib/oeqa/runtime/buildsudoku.py
> @@ -1,4 +1,4 @@
> -from oeqa.oetest import oeRuntimeTest
> +from oeqa.oetest import oeRuntimeTest, skipModule
>  from oeqa.utils.decorators import *
>  from oeqa.utils.targetbuild import TargetBuildProject
> 
> diff --git a/meta/lib/oeqa/runtime/ldd.py b/meta/lib/oeqa/runtime/ldd.py
> index 4374530..079130f 100644
> --- a/meta/lib/oeqa/runtime/ldd.py
> +++ b/meta/lib/oeqa/runtime/ldd.py
> @@ -1,5 +1,5 @@
>  import unittest
> -from oeqa.oetest import oeRuntimeTest
> +from oeqa.oetest import oeRuntimeTest, skipModule
>  from oeqa.utils.decorators import *
> 
>  def setUpModule():
> diff --git a/meta/lib/oeqa/runtime/pam.py b/meta/lib/oeqa/runtime/pam.py
> index cc5c1bd..c26e6ea 100644
> --- a/meta/lib/oeqa/runtime/pam.py
> +++ b/meta/lib/oeqa/runtime/pam.py
> @@ -2,7 +2,7 @@
>  # Note that the image under test must have "pam" in DISTRO_FEATURES
> 
>  import unittest
> -from oeqa.oetest import oeRuntimeTest
> +from oeqa.oetest import oeRuntimeTest, skipModule
>  from oeqa.utils.decorators import *
> 
>  def setUpModule():
> @@ -17,8 +17,8 @@ class PamBasicTest(oeRuntimeTest):
>          (status, output) = self.target.run('login --help')
>          self.assertEqual(status, 1, msg = "login command does not work as
> expected. Status and output:%s and %s" %(status, output)) (status, output)
> = self.target.run('passwd --help')
> -        self.assertEqual(status, 0, msg = "passwd command does not work as
> expected. Status and output:%s and %s" %(status, output)) +       
> self.assertEqual(status, 6, msg = "passwd command does not work as
> expected. Status and output:%s and %s" %(status, output)) (status, output)
> = self.target.run('su --help')
> -        self.assertEqual(status, 0, msg = "su command does not work as
> expected. Status and output:%s and %s" %(status, output)) +       
> self.assertEqual(status, 2, msg = "su command does not work as expected.
> Status and output:%s and %s" %(status, output)) (status, output) =
> self.target.run('useradd --help')
> -        self.assertEqual(status, 0, msg = "useradd command does not work as
> expected. Status and output:%s and %s" %(status, output)) +       
> self.assertEqual(status, 2, msg = "useradd command does not work as
> expected. Status and output:%s and %s" %(status, output))

Stefan pointed out to me that this contains a seemingly unintentional revert 
of the following earlier change:

http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/meta/lib/oeqa/runtime/pam.py?id=14735be703de1b1e173d444b51df7aad902428d5

Cheers,
Paul

-- 

Paul Eggleton
Intel Open Source Technology Centre



More information about the Openembedded-core mailing list