On 6/22/20 10:33 AM, Andrej Valek wrote:
The output content is created in current directory, because json content
has no defined absolute path to WORKDIR as in bitbake.
Signed-off-by: Andrej Valek <[email protected]>
Signed-off-by: Peter Marko <[email protected]>
---
meta/lib/oeqa/runtime/cases/ptest.py | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/meta/lib/oeqa/runtime/cases/ptest.py
b/meta/lib/oeqa/runtime/cases/ptest.py
index 1b1474adcf..919901d465 100644
--- a/meta/lib/oeqa/runtime/cases/ptest.py
+++ b/meta/lib/oeqa/runtime/cases/ptest.py
@@ -42,6 +42,10 @@ class PtestRunnerTest(OERuntimeTestCase):
# testdata.json is generated.
if not test_log_dir:
test_log_dir = os.path.join(self.td.get('WORKDIR', ''),
'testimage')
+ # Make the test output path absolute, otherwise the output content
will be
+ # is created relative to current directory
'is' is not needed in above comment.
+ if not os.path.isabs(test_log_dir):
+ test_log_dir = os.path.join(self.td.get('TOPDIR', ''),
test_log_dir)
will it expose full paths in final logs ? that may be shared publically ?
# Don't use self.td.get('DATETIME'), it's from testdata.json, not
# up-to-date, and may cause "File exists" when re-reun.
timestamp = datetime.datetime.now().strftime('%Y%m%d%H%M%S')
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#139752):
https://lists.openembedded.org/g/openembedded-core/message/139752
Mute This Topic: https://lists.openembedded.org/mt/75043742/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-