diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-05-09 17:02:39 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-05-13 16:28:35 +0100 |
commit | 521a3f727c983ddfb877c3dfe653f70ce912413e (patch) | |
tree | 8c3bb272e6a17b86b5dd8c74b19fcce5c0b77799 | |
parent | 45e819b4d45c64104b57845eec0a07b54d889c2a (diff) | |
download | poky-521a3f727c983ddfb877c3dfe653f70ce912413e.tar.gz |
insane: Fix case where S doesn't exist
If S doesn't exist, do_qa_patch would fail. Fix the code to not fail
in this situation.
(From OE-Core rev: 4041d91b63ff2315657499e22c74ec90adbf9e19)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/classes-global/insane.bbclass | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/classes-global/insane.bbclass b/meta/classes-global/insane.bbclass index c32dfffd83..03ac06b102 100644 --- a/meta/classes-global/insane.bbclass +++ b/meta/classes-global/insane.bbclass | |||
@@ -1399,7 +1399,7 @@ python do_qa_patch() { | |||
1399 | oe.qa.handle_error("unimplemented-ptest", "%s: autotools-based tests detected" % d.getVar('PN'), d) | 1399 | oe.qa.handle_error("unimplemented-ptest", "%s: autotools-based tests detected" % d.getVar('PN'), d) |
1400 | 1400 | ||
1401 | # Last resort, detect a test directory in sources | 1401 | # Last resort, detect a test directory in sources |
1402 | elif any(filename.lower() in ["test", "tests"] for filename in os.listdir(srcdir)): | 1402 | elif os.path.exists(srcdir) and any(filename.lower() in ["test", "tests"] for filename in os.listdir(srcdir)): |
1403 | oe.qa.handle_error("unimplemented-ptest", "%s: test subdirectory detected" % d.getVar('PN'), d) | 1403 | oe.qa.handle_error("unimplemented-ptest", "%s: test subdirectory detected" % d.getVar('PN'), d) |
1404 | 1404 | ||
1405 | oe.qa.exit_if_errors(d) | 1405 | oe.qa.exit_if_errors(d) |