diff options
author | Laurent Bonnans <laurent.bonnans@here.com> | 2019-07-08 11:28:34 +0200 |
---|---|---|
committer | Laurent Bonnans <laurent.bonnans@here.com> | 2019-07-17 18:28:28 +0200 |
commit | 4ab468bc0cb76f5d13b24af35e0d7746a0c035ad (patch) | |
tree | 5fd1f847b83bb86a404e1d1bae2563a11ae4b379 /lib/oeqa/selftest/cases/testutils.py | |
parent | 144d9b25815300fc98157ea411081e898b7457f9 (diff) | |
download | meta-updater-4ab468bc0cb76f5d13b24af35e0d7746a0c035ad.tar.gz |
Factor out ugly function in oe-selftests
Signed-off-by: Laurent Bonnans <laurent.bonnans@here.com>
Diffstat (limited to 'lib/oeqa/selftest/cases/testutils.py')
-rw-r--r-- | lib/oeqa/selftest/cases/testutils.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/oeqa/selftest/cases/testutils.py b/lib/oeqa/selftest/cases/testutils.py index 900d15c..e67f30c 100644 --- a/lib/oeqa/selftest/cases/testutils.py +++ b/lib/oeqa/selftest/cases/testutils.py | |||
@@ -69,6 +69,16 @@ def qemu_send_command(port, command, timeout=60): | |||
69 | return stdout, stderr, s2.returncode | 69 | return stdout, stderr, s2.returncode |
70 | 70 | ||
71 | 71 | ||
72 | def metadir(): | ||
73 | # Assume the directory layout for finding other layers. We could also | ||
74 | # make assumptions by using 'show-layers', but either way, if the | ||
75 | # layers we need aren't where we expect them, we are out of luck. | ||
76 | path = os.path.abspath(os.path.dirname(__file__)) | ||
77 | metadir = path + "/../../../../../" | ||
78 | |||
79 | return metadir | ||
80 | |||
81 | |||
72 | def akt_native_run(testInst, cmd, **kwargs): | 82 | def akt_native_run(testInst, cmd, **kwargs): |
73 | # run a command supplied by aktualizr-native and checks that: | 83 | # run a command supplied by aktualizr-native and checks that: |
74 | # - the executable exists | 84 | # - the executable exists |