summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa
Commit message (Collapse)AuthorAgeFilesLines
* selftest/signing: Ensure build path relocation is safeRichard Purdie2020-09-101-1/+3
| | | | | | | | | Similarly to 04ee0e8b95cd8ed890374e0007f976684206b630, ensure only full build paths are replaced in the environment to avoid breaking buildtools. (From OE-Core rev: db8ceed8f2eca92a4cffe8295481d8041281fdd0) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/runtime_test: Disable test_testimage_virgl_gtkRichard Purdie2020-09-101-1/+1
| | | | | | | | | | | | This test keeps failing on the autobuilder and is proving extremely annoying. It works much better in later releases but for zeus and earlier, lets just stop running it as it doesn't really tell us anything useful at this point, nobody has any plans to improve the distro exclusions or otherwise fix it in the older releases. (From OE-Core rev: 290b9083b539a938fe8e12d5b17bb1348644a4e8) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest: Ensure buildtools in environment variables isn't replacedRichard Purdie2020-09-101-1/+1
| | | | | | | | | | | | | This avoids the seeing broken replacements like: oe-selftest-centos/build/build-st-926tools/sysroots/x86_64-pokysdk-linux/etc/ssl/certs/ca-certificates.crt which understandably break builds. (From OE-Core rev: 04ee0e8b95cd8ed890374e0007f976684206b630) (Cherry-picked from f930e2cadb9ee69759720b6c49aeeb6dd43a7edd but adjusted for thud) (From OE-Core rev: 3841b0e2a2e1c1ebd296c6057831b3e463fcba69) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/testsdk: Use original PATHRichard Purdie2020-09-101-5/+2
| | | | | | | | | | | | | | | | We want to test the SDK with PATH from the original host, not with our own tools injected via HOSTTOOLS. It even uses some tools which aren't in HOSTTOOLS. This is necessary after changing the SDK to not reset PATH to the system default which is bad for other reasons and brings the testing into sync with that change. (From OE-Core rev: 87c9602fd0dedc7bcf75b822aaf5f6ebfc17737c) (From OE-Core rev: e58bc5ea7d4da2e50e1820e80a5f906ce38d2372) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* selftest/context: Avoid tracebacks from tests using multiprocessingRichard Purdie2020-08-041-1/+5
| | | | | | | | | | | | | | | | | We can see tracebacks where the SIGTERM handler catches things it shouldn't. Avoid exit(1) unless we're the process that it was intended for. [YOCTO #13664] (From OE-Core rev: d9c62ffac611310efd47ed6397d31dccb72fe868) (From OE-Core rev: 45b4bd7b4d30d81bdff0d471e8d97c2322ed2f75) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit dba8c1d5ef0b574b7772d59e5992bfad8b7cca13) Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* targetcontrol: Fix leaking log handlerRichard Purdie2020-06-021-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | We had a mystery failure on the autobuilder where runqemu appeared to be failing as a logfile directory no longer existed. The key to reproducing was running a runqemu where the image was deleted (as devtool does), then running another runqemu test. E.g.: 'oe-selftest -r devtool.DevtoolExtractTests.test_devtool_deploy_target wic.Wic2.test_qemu_efi' This then tries to write to the logfile from the first test, the image directory was deleted and we get strange failures. The fix is to remove the logging handler when qemu is stopped. (From OE-Core rev: 924b020eacf111b4fd4d731b363084e254a3422d) (From OE-Core rev: 6893eb741c4cd4849e2fde1f86d9911b6c89db5b) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 9b335fa867805f612154ae92c5a1e727d3fb29ca) Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/qemurunner: Clean up failure handlingRichard Purdie2020-06-021-3/+8
| | | | | | | | | | | | | | | | | | | | | | If you fail to setup the tap devices, runqemu will error quickly however stdout/stderr are not shown to the user, instead a SystemExit traceback is shown. This could explain some long since unexplained failures on the autobuilder. Rework the error handling so SystemExit isn't used and the standard log failure messages can be shown. The code could likely ultimatley need some restructuring to work effectively. (From OE-Core rev: 83b8e66b66aa9848ed9c8761a21cb47c6443d0c6) (From OE-Core rev: 19120fce4f55f6a2903812ed9461273a85cb3544) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit e820c86fb9ddfadea0c27f29e14b985ee3178320) Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* qemurunner.py: add try/except for pid handling raceTrevor Gamblin2020-03-071-1/+4
| | | | | | | | | | | | | | | | | | | In some instances, attempts to remove the qemu pidfile within the stop() method fail despite the os.path.exists() call immediately before implying that the file is present. Add a try/except block to log a warning if this occurs, rather than failing outright, since the process simply appears to be exiting at an inconvenient time. [YOCTO #13675] (From OE-Core rev: 0e94cfb4aa718b4842f608879b77d5671b5bf338) Signed-off-by: Trevor Gamblin <trevor.gamblin@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit eadb899e23b18eb9eaff145c3bf5b20fb417c3e8) Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/reproducible: Improve test output and ensure deb+ipk comparedRichard Purdie2020-02-111-2/+7
| | | | | | | | | | | | | | | | | | | Adding newline characters between the packages in the failure output massively improves readability. Also ensure to output ipk failures when there are deb failures by calling self.fail() at the end, else sometimes only partial differences are returned. (From OE-Core rev: 6e2e0480852177db75a6108d77c99c92c4e9950f) (From OE-Core rev: 4d470f48f7fb5e05fba1ca3a59fb4f85d910026e) (From OE-Core rev: 38359c79dc6e02a21d1bc26756c8bd88da762ef8) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* multilib.conf: Ensure that RECIPE_SYSROOT is unchanged for nativeMike Crowe2020-01-281-0/+40
| | | | | | | | | | | | | | | | | | | | | | | Ensure that RECIPE_SYSROOT is the same for -native recipes whether multilib.conf is included or not. Without this change task signatures for -native recipes change when switching between MACHINEs that require multilib.conf and those that don't. This fix was one of the ones suggested by Khem Raj in http://lists.openembedded.org/pipermail/openembedded-core/2019-December/290303.html Add test_sstate_multilib_or_not_native_samesigs test case to sstatetests.py to ensure that this stays fixed. (From OE-Core rev: c3e957409bf68e7b310e27781ac91d24cf4452bf) Signed-off-by: Mike Crowe <mac@mcrowe.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit aa05f1ded71366b86eda7fce24d8b5395e85ada2) Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* license.bbclass: Introduce AVAILABLE_LICENSES that lists all licensesPeter Kjellerstedt2020-01-281-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | Previously, there was SRC_DISTRIBUTE_LICENSES, an undocumented variable that contained a static list of licenses. It was used by expand_wildcard_licenses() to expand any wildcards used in, e.g., INCOMPATIBLE_LICENSE. However, since this static list of licenses has not been kept up-to-date, many licenses were missing, with the result that if one tried to use any of those licenses with a wildcard, no licenses would be found, effectively ignoring that they should be marked as incompatible. This introduces a new (documented) variable, AVAILABLE_LICENSES, that is automatically updated to contain all licenses found in any directories specified by ${COMMON_LICENSE_DIR} and ${LICENSE_PATH}, and uses it instead of SRC_DISTRIBUTE_LICENSES when expanding wildcards. (From OE-Core rev: 5ed714139f91eb03871e01b68a4370784071234d) Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 8c9ef587fe499c612a878a1ab42092eb79b334ef) Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* sanity.bbclass: Move sanity_info from conf to cachePeter Kjellerstedt2020-01-281-1/+1
| | | | | | | | | | | | | | | | | Since this file is written during recipe parsing, having it in the ${BUILDDIR}/conf directory, which is covered by an inotify watcher, will trigger a re-parse the next time bitbake is run and the resident bitbake server is enabled. This causes the sanity_info file to be updated again, which triggers a new parse the next time bitbake is run ad infinitum. Moving it to ${BUILDDIR}/cache should avoid this. (From OE-Core rev: f1a609e7176a37e7e5f86f0b786f7da915085f83) Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit f98103b548aa7dba6b1be6c8e02ef41858a8e85c) Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa: reproducible: Add option to capture bad packagesJoshua Watt2019-11-251-0/+20
| | | | | | | | | | | | | Adds an option that can be used to copy the offending packages to a temp directory for later evaluation. This is useful on the Autobuilder to investigate failures. (From OE-Core rev: 91d657a0c4cbb273e1e74d38bfd6b4b05d9b372e) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* selftest: check that 'devtool upgrade' correctly drops backported patchesAlexander Kanavin2019-11-251-3/+22
| | | | | | | | | | | | There was a regression in this functionality that went unnoticed due to lack of tests. (From OE-Core rev: da4c28d5fdc6501a7d3b256cb62cba778e81d16e) Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/sstatetests: Ensure we don't use hashequiv for sstatesigs testsRichard Purdie2019-11-251-0/+12
| | | | | | | | (From OE-Core rev: 7f424c32589b94192842f52235c064cb8c19288e) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* selftest: skip virgl test on centos 7 entirelyAlexander Kanavin2019-11-131-0/+2
| | | | | | | | | | | | With the sdl frontend, qemu isn't able to even boot fully, so let's skip the test early. (From OE-Core rev: 1344a6a1300007b4fadaf815f6652d30e7834430) Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/imagefeatures: improve test_hypervisor_fmtsRoss Burton2019-10-091-2/+6
| | | | | | | | | | If this test fails then the output doesn't help in any meaningful way, so improve the test to output the unparsable JSON and display unexpected output. (From OE-Core rev: 6a710ad0b445295991b17545f634684f4f317099) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* dnf.py: check busybox for case test_dnf_installrootKai Kang2019-10-091-0/+2
| | | | | | | | | | Check package busybox which is required by cases test_dnf_installroot and test_dnf_installroot_usrmerge. (From OE-Core rev: 0f09c5b7a9a66af825951354b436b69dd9a596a4) Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/sdk: improve Meson testRoss Burton2019-10-091-1/+3
| | | | | | | | | Verify that the build inside the SDK is detected as a cross compilation. (From OE-Core rev: 3dc75ab44c23c4ff26502b96abded3c1c0b94e38) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/core/case.py: Encode binary data of logNathan Rossi2019-09-301-2/+2
| | | | | | | | | | | | | | | Do not decode the log content into a string only to re-encode it as binary data again. Some logs might un-intentionally contain bytes that do not decode as utf-8, as such preserve the log file content as it was on disk. Handle the decoding on the resulttool side, but also handle the failure to decode the data. (From OE-Core rev: 20531dc0b8f76a6e37cc856f36cd94077b6aba50) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/core/utils/concurrencytest.py: Handle exceptions and detailsNathan Rossi2019-09-301-13/+18
| | | | | | | | | | | | | | | | | Handle the streaming of exception content with details data. The testtools package allows both 'err' and 'details' kwargs but can only pass one of them to the parent. To handle the passing of exception traceback and details data at the same time, encode the traceback into the details object and remove the 'err' arg from the add* result call. This encodes the traceback similar to how 'err' is handled without any details object. Decoding is already done by testtools when the traceback is encoded in the details object. (From OE-Core rev: 3613451825b251784b7673d89db465b9782c3a31) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/signing: Fix for hash equivlance serverRichard Purdie2019-09-301-2/+5
| | | | | | | | | | | | | | There were two issues with the test one is that an equivalent hash could come from the server meaning the signature didn't change when it should. A uuid string is injected to ensure this does not happen. If there were multiple warnings the test would also fail as only the first is prefixed with WARNING. Tweak the string to avoid that failure mode. (From OE-Core rev: e58eaf5b8c93521dc311b77593e0dd7debca602d) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa: Test multiconfig parsingJoshua Watt2019-09-272-15/+47
| | | | | | | | | | | | Add a test to verify that when multiconfig conf files changed, recipes are correctly reparsed. [YOCTO #13541] (From OE-Core rev: a424ef0a0c49123f4518e8fef993fd10f6fc5f4e) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* cases/bbtests.py: test_bitbake_g(): Check base-files rather than busyboxRobert Yang2019-09-271-2/+3
| | | | | | | | | | | | | | | | | | | | It checked whether busybox is in task-depends.dot after run "bitbake -g core-image-minimal", but busybox is not a must for core-image-minimal since it is configurable: VIRTUAL-RUNTIME_base-utils = "" VIRTUAL-RUNTIME_base-utils-syslog = "" VIRTUAL-RUNTIME_base-utils-hwclock = "" VIRTUAL-RUNTIME_login_manager = "shadow" VIRTUAL-RUNTIME_syslog = "" So the case may fail when busybox is not present, check base-files which is more reliable. (From OE-Core rev: f73676b07f6d8a4573a5f46c3e082831b34b7d18) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* devtool.py: fix buildclean testChangqing Li2019-09-271-0/+1
| | | | | | | | | | | | | | | | | | when build with EXTERNALSRC, checksum of EXTERNALSRC is one of inputs for generate sigdata of task do_compile. without change any source, the sigdata will not changed, and buildclean task only do make clean, and not clean stampfiles like clean task, so the stampfile keep there, then do_compile after do_buildclean will not rerun, and targetfile tempdir_mdadm/mdadm will not be generated, report below error: AssertionError: '/tmp/devtoolqarxv8ct6u/mdadm' does not exist Fix by add a comments in Makefile to trigger rebuild of compile task (From OE-Core rev: f4621cf4516f9de9980f3864a193f3f61c4abedc) Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* devtool.py: change to do clean before remove-layerChangqing Li2019-09-271-7/+7
| | | | | | | | | | | | | | | if do clean after remove-layer, it will make stamp file not cleaned since variable STAMP has changed, this will cause error like: if testcase buildclean failed, when run next testcase modify, since do_prepare_recipe_sysroot's stamp file exists, sysroot not populated, then do_compile will fail with error: /bin/sh: x86_64-poky-linux-gcc: command not found (From OE-Core rev: 046d7e1de094105db0949c2cf5333ff55d9ad9c8) Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/reproducible: test ipkgs tooRoss Burton2019-09-271-1/+1
| | | | | | | | | | | | Now that opkg-build can build reproducible ipkgs, we can also add those to the test case. [ YOCTO #13513 ] (From OE-Core rev: 3806d38e6194a42534381993fcfcc3ff39550a13) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/concurrenttest: Use ionice to delete build directoriesRichard Purdie2019-09-191-1/+1
| | | | | | | | | | | | | | | | Autobuilder type infrastructure can benefit from deletion of certain files as background IO due to the way Linux filesystem priority works. We have problems where build directories as part of oe-selftest being delete starves the running tasks of IO to the point builds take much longer to compelte. Having this option of running the deletion at "idle" helps a lot with that. Use the new option added to bb.utils.prunedir(). (From OE-Core rev: d41e7018be56902b7a1be4590e468cd15e02a3b5) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/imagefeatures: dump the JSON if it can't be parsedRoss Burton2019-09-161-1/+2
| | | | | | | (From OE-Core rev: 4f7c840349f576f3edb68b16f9bcc9d88bc73b36) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/wic: improve assert messages in test_fixed_sizeRoss Burton2019-09-161-2/+4
| | | | | | | (From OE-Core rev: ff4e6c71ac415de93b3abaa4e7f1727d72cd2971) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* runqemu: decouple gtk and gl optionsAlexander Kanavin2019-09-161-1/+1
| | | | | | | | | | | This will allow not having to multiply these options for the sdl frontend, instead combining them as needed. (From OE-Core rev: 922eb5012364b1603338cfa617712b941e892bbf) Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa: add case for oe-git-proxyHenning Schild2019-09-161-0/+58
| | | | | | | | | | | The escaping, splitting and matching of NO_PROXY in oe-git-proxy deserves its own testcase, add it. (From OE-Core rev: c07134711f97c966d70aaf2798800214d5426005) Signed-off-by: Henning Schild <henning.schild@siemens.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest: Rework toolchain tests to use OEPTestResultTestCaseNathan Rossi2019-09-163-12/+15
| | | | | | | | | | Use OEPTestResultTestCase to collect results and add logfile collection and compression. (From OE-Core rev: b75aced558013a459f29617b53cf477cb9b387ac) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/core/case.py: Add OEPTestResultTestCase for ptestresult helpersNathan Rossi2019-09-161-0/+49
| | | | | | | | | | | | | | | | Add the OEPTestResultTestCase class as a mix-in class to provide helper functions for interacting with ptestresults within the extraresults object generated by the test case. This class also provides default compression of log text and log files. Also add support to resulttool for decoding/decompressing log files embedded in the test results. (From OE-Core rev: 06cba9883a5964320969301fd05eeb6bec3e786d) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/context.py: For -t/-T use append argparse actionNathan Rossi2019-09-111-6/+6
| | | | | | | | | | | | | Use the 'append' action of argparse instead of nargs. This changes the behaviour of the option from "-t foo bar -r" to "-t foo -t bar -r". Additionally rename the long form options to be consistent with behaviour, such that they specifying a single tag at a time. (From OE-Core rev: ffe9e4303fa9799d2e8af9188853a262e15af226) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest: Tweak binutils tests tags as toolchain/user and systemRichard Purdie2019-09-071-1/+1
| | | | | | | | This matches the other toolchain tests. (From OE-Core rev: d41606244c170fd547496e5df9e3d28ce2d2af68) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/cases/glibc.py: Rework and tag with toolchain-user/systemNathan Rossi2019-09-071-21/+25
| | | | | | | | | | Rework the glibc execution into a common base class. Additionally tag the tests with "toolchain-user" and "toolchain-system". (From OE-Core rev: 94bf24268108774e022ad247c647e48a781debbb) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/cases/gcc.py: Split into classes for parallelismNathan Rossi2019-09-071-30/+71
| | | | | | | | | | | | | | Split the gcc selftest cases into multiple classes one for each test. This is done in order to make it easy to execute multiple gcc tests in parallel when using oe-selftest with the '-j' arg. Additionally tag the user tests with "toolchain-user" and the system emulation (qemu system) tests with "toolchain-system". (From OE-Core rev: 7b2f03eff9fc9b4ce48d5ea7e54faa114a6cdcae) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/core/decorator: Fix super class modifying subclass tagsNathan Rossi2019-09-071-1/+2
| | | | | | | (From OE-Core rev: ba35bead1108c7d8480b785b2e59f40ea77b5549) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/context.py: Change -t/-T args to be optionalNathan Rossi2019-09-071-11/+19
| | | | | | | | | | | Change the -t/-T args to be optional so that they can be used together with the existing -r/-a/... args to run a more flexible filtering of test tags. (From OE-Core rev: 55ee27bb07113a45da18711b5509764f62be4d75) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest: Use extraresults on self instead of self.tcNathan Rossi2019-09-074-41/+12
| | | | | | | | | | | | | In order to take advantage of multiprocess execution of tests the extraresults must be passed through the TestResult. With changes to how oeqa/core handles test cases the extraresults attribute of the testcase is passed to the TestResult, with passing across process boundaries handled automatically. (From OE-Core rev: 6a1b0c2003a0b4a1983f9494440e6ea02dc25585) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest: Toolchain tests suffix "-user" for qemu usermode resultsNathan Rossi2019-09-072-2/+4
| | | | | | | | | | Suffix the ptestresults suite with "-user" for tests that are executing against usermode qemu. (From OE-Core rev: 0becf9c1fabb080a2481ebdacef6221f52301621) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest: For toolchain tests do not fail if a test failedNathan Rossi2019-09-073-17/+0
| | | | | | | | | | | | | Do not fail the running selftest test case if the test suite has a failed test case. Currently toolchain tests suites (binutils, gcc, glibc) fail but this does not indicate failure to execute the tests. Also remove the logging of each test that failed. (From OE-Core rev: 073575ff9c06b2791cc2bd88063d815d2220f038) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/cases/glibc.py: Don't install python3 and pexpectNathan Rossi2019-09-071-2/+2
| | | | | | | | | | | When running the system emulation test case, do not include python3 or pexpect in the image. The test cases that use these also need gdb (with python configured). (From OE-Core rev: 7e5be0803ea0cbfd8e5b052e43b54e16ab3230ed) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/glibc: Create selftest case for glibc test suiteNathan Rossi2019-09-071-0/+97
| | | | | | | | | | | | | | | | | Create a oeqa selftest test case to execute the glibc test suite and report the results. The results are populated into the extraresults variable of the test case which are written to testresults.json for resulttool to analyse. An additional subclass is created to separate the execution with qemu linux-user and qemu system. The GlibcSelfTestSystemEmulated test case handles setup of the target image, setup of and NFS server as well as execution with runqemu. (From OE-Core rev: 730832ebcca305477e1c13248cd35eea095b35c6) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/gcc: Create selftest case for gcc test suiteNathan Rossi2019-09-071-0/+111
| | | | | | | | | | | | | | | | Create a oeqa selftest test case to execute the gcc test suites and report the results. The results are populated into the extraresults variable of the test case which are written to testresults.json for resulttool to analyse. An additional subclass is created to separate the execution with qemu linux-user and qemu system. The GccSelfTestSystemEmulated test case handles setup of the target image as well as execution with runqemu. (From OE-Core rev: 2c86a25f8992243311e7fa1a8654b41f12b749de) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest/binutils: Create selftest case for binutils test suiteNathan Rossi2019-09-071-0/+64
| | | | | | | | | | | | Create a oeqa selftest test case to execute the binutils test suites and report the results. The results are populated into the extraresults variable of the test case which are written to testresults.json for resulttool to analyse. (From OE-Core rev: e5629aa4bd939072208f6eb5b30a98e17eb6a8ae) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest: Markup 'machine' specific test casesRichard Purdie2019-09-072-0/+4
| | | | | | | | | | These test cases are run by the autobuilder on a machine specific basis. Add tags to these classes so they can be controlled by the metadata rather than hardcoded in the autobuilder config. (From OE-Core rev: de0b761b550d591f301ee5e9c232e0d5bd1342f2) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/core/runner.py: Fix OETestTag listingNathan Rossi2019-09-071-11/+8
| | | | | | | | | | | | Use the __oeqa_testtags attribute added by OETestTag and display no, one or more tags separated by a comma. Also change the formatting of the output so that the list of tests is formatted as "<test> (<tags>)" and remove the table header for "id" (it is no longer available). (From OE-Core rev: d62e577a4e1a5f6accbce9f7bff7317a1162d72d) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* oeqa/selftest: Add test run filtering based on test tagsNathan Rossi2019-09-071-0/+11
| | | | | | | | | | | Add '--run-only-tags' for running tests which match any of the provided tags, and '--run-exclude-tags' for running all tests except those that have any of the provided tags. (From OE-Core rev: 0dc3caf21c4519ef16c2ac99b93c03e23aab61d9) Signed-off-by: Nathan Rossi <nathan@nathanrossi.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>