summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa/runtime/context.py
diff options
context:
space:
mode:
Diffstat (limited to 'meta/lib/oeqa/runtime/context.py')
-rw-r--r--meta/lib/oeqa/runtime/context.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/meta/lib/oeqa/runtime/context.py b/meta/lib/oeqa/runtime/context.py
index bc8abd0c4e..10b8b54809 100644
--- a/meta/lib/oeqa/runtime/context.py
+++ b/meta/lib/oeqa/runtime/context.py
@@ -15,12 +15,14 @@ class OERuntimeTestContext(OETestContext):
15 runtime_files_dir = os.path.join( 15 runtime_files_dir = os.path.join(
16 os.path.dirname(os.path.abspath(__file__)), "files") 16 os.path.dirname(os.path.abspath(__file__)), "files")
17 17
18 def __init__(self, td, logger, target, host_dumper, image_packages): 18 def __init__(self, td, logger, target,
19 host_dumper, image_packages, extract_dir):
19 super(OERuntimeTestContext, self).__init__(td, logger) 20 super(OERuntimeTestContext, self).__init__(td, logger)
20 21
21 self.target = target 22 self.target = target
22 self.image_packages = image_packages 23 self.image_packages = image_packages
23 self.host_dumper = host_dumper 24 self.host_dumper = host_dumper
25 self.extract_dir = extract_dir
24 self._set_target_cmds() 26 self._set_target_cmds()
25 27
26 def _set_target_cmds(self): 28 def _set_target_cmds(self):
@@ -45,6 +47,7 @@ class OERuntimeTestContextExecutor(OETestContextExecutor):
45 default_server_ip = '192.168.7.1' 47 default_server_ip = '192.168.7.1'
46 default_target_ip = '192.168.7.2' 48 default_target_ip = '192.168.7.2'
47 default_host_dumper_dir = '/tmp/oe-saved-tests' 49 default_host_dumper_dir = '/tmp/oe-saved-tests'
50 default_extract_dir = 'extract_dir'
48 51
49 def register_commands(self, logger, subparsers): 52 def register_commands(self, logger, subparsers):
50 super(OERuntimeTestContextExecutor, self).register_commands(logger, subparsers) 53 super(OERuntimeTestContextExecutor, self).register_commands(logger, subparsers)
@@ -72,6 +75,9 @@ class OERuntimeTestContextExecutor(OETestContextExecutor):
72 runtime_group.add_argument('--packages-manifest', action='store', 75 runtime_group.add_argument('--packages-manifest', action='store',
73 help="Package manifest of the image under test") 76 help="Package manifest of the image under test")
74 77
78 runtime_group.add_argument('--extract-dir', action='store',
79 help='Directory where extracted packages reside')
80
75 runtime_group.add_argument('--qemu-boot', action='store', 81 runtime_group.add_argument('--qemu-boot', action='store',
76 help="Qemu boot configuration, only needed when target_type is QEMU.") 82 help="Qemu boot configuration, only needed when target_type is QEMU.")
77 83
@@ -126,4 +132,8 @@ class OERuntimeTestContextExecutor(OETestContextExecutor):
126 OERuntimeTestContextExecutor.readPackagesManifest( 132 OERuntimeTestContextExecutor.readPackagesManifest(
127 args.packages_manifest) 133 args.packages_manifest)
128 134
135 self.tc_kwargs['init']['extract_dir'] = \
136 OERuntimeTestContextExecutor.readPackagesManifest(
137 args.extract_dir)
138
129_executor_class = OERuntimeTestContextExecutor 139_executor_class = OERuntimeTestContextExecutor