[gnome-continuous-yocto/gnomeostree-3.28-rocko: 6037/8267] oeqa/sdk/context.py: Import argparse_oe at OESDKTestContext.run method



commit 13175d8d48fab9449c144d7c5f332b9682ae13e9
Author: Aníbal Limón <anibal limon linux intel com>
Date:   Fri May 26 15:37:28 2017 -0500

    oeqa/sdk/context.py: Import argparse_oe at OESDKTestContext.run method
    
    This import was at level of OESDKTestContext.register_commands
    but OESDKTestContext.run method need it to raise exceptions.
    
    (From OE-Core rev: 35efb419de1dbebd269d87895645934707130746)
    
    Signed-off-by: Aníbal Limón <anibal limon linux intel com>
    Signed-off-by: Richard Purdie <richard purdie linuxfoundation org>

 meta/lib/oeqa/sdk/context.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/meta/lib/oeqa/sdk/context.py b/meta/lib/oeqa/sdk/context.py
index 0189ed8..509d2b4 100644
--- a/meta/lib/oeqa/sdk/context.py
+++ b/meta/lib/oeqa/sdk/context.py
@@ -44,8 +44,6 @@ class OESDKTestContextExecutor(OETestContextExecutor):
     default_test_data = None
 
     def register_commands(self, logger, subparsers):
-        import argparse_oe
-
         super(OESDKTestContextExecutor, self).register_commands(logger, subparsers)
 
         sdk_group = self.parser.add_argument_group('sdk options')
@@ -109,6 +107,8 @@ class OESDKTestContextExecutor(OETestContextExecutor):
             log(env)
 
     def run(self, logger, args):
+        import argparse_oe
+
         if not args.sdk_dir:
             raise argparse_oe.ArgumentUsageError("No SDK directory "\
                    "specified please do, --sdk-dir SDK_DIR", self.name)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]