| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
| |
along with systemd upgrade, error message related change
network interface have changed, update it.
(From OE-Core rev: a8b2cd7470bcc25527577b95a26a0a528949232d)
Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* with Ubuntu 20.04 which is using python 3.8 I'm seeing a lot of errors like:
ERROR: libxml2-2.9.10-r0 do_package: Can NOT get PRAUTO, exception No module named '_sysconfigdata'
not sure what caused this from python 3.8, but this seems to work
* PRserv is enabled with:
PRSERV_HOST = "localhost:0"
(From OE-Core rev: 4b26eaf7152fb712aba47a0c746333578f58ee8d)
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As opkglibdir starts with a /, os.path.join will ignore
self.target_rootfs, leading to an attempt to remove /var/lib/opkg.
This only fails if it exists on the host, explaining why this remained
undiscovered for long.
(From OE-Core rev: fc974977cea389f54e7fc7de7b1c8fd3d8bafe58)
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If there already is a package providing (and conflicting against)
packages what should be installed, apt will try remove the conflicting
package (target-sdk-provides-dummy) and any that depend on it (like apt
and dpkg). This usually fails because of the protection of essential
packages. In that case, no -dev/-dbg packages are installed to the SDK.
Avoid this problem by checking which packages are already provided and
removing them from the list to be installed. Also sort the list to make
it easier to read when debugging.
(From OE-Core rev: 3ffb339dd55f8ca7c952fd3390608510f772e19f)
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
This is needed for a later change to avoid installing packages which are
already provided by an installed package.
(From OE-Core rev: ad72dfaaa2caf2c39d033dc1682f0bbbbe45dbbd)
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In commit 7d214b34e11dc57316ed5c1c7747c4601286f6d2, only the code in the
for loop was modified to store the pkgarch value. The code used if there
was no empty line at the end was not modified.
Instead of fixing the duplicated code, remove it and just make sure that
a final empty line is processed.
(From OE-Core rev: a7b93c695b23d015607b179d98526b9b14c03d45)
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
apt install can decide to remove already installed packages if there are
conflicts. Avoid this by explicitly specifying --no-remove. This will
then cause a "E: Packages need to be removed but remove is disabled."
message.
(From OE-Core rev: 9605a488b55042add012e9aeef13ab3f4e70e6e5)
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add helper function to get the host compiler and version.
Do not assume compiler is gcc.
NOTE: cannot set env to d.getVar("PATH") as that does not contain
the session PATH which was set by environment-setup-... which
breaks the install-buildtools use-case
(From OE-Core rev: 88712929354ff9c876bb1e48b6f15c33af5f2bbc)
Signed-off-by: Tim Orling <timothy.t.orling@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
| |
(From OE-Core rev: e7f025c87d595d2e37f83b75f11bedf2bce7bcc0)
Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Utils can not detect GCC 10 correctly due to wrong regex.
It generates this error "ERROR: Can't get compiler version from gcc --version output"
Sub-version numbers should be 1 or more digits instead of 1 only.
(From OE-Core rev: 186fe4a3d390a52b87282c3e694ce3251e45ee78)
Signed-off-by: Charles-Antoine Couret <charles-antoine.couret@mind.be>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Set the json result output dir in the oeqe runtime context to create
testresults.json file by default for exported runtime test runs.
Use current datetime for the json result property name (not DATETIME
from build) to allow multiple result entries.
(From OE-Core rev: e6c73ed8d3c5d45f387cab619ca73c21e850582f)
Signed-off-by: Stefan Kral <sk@typedivision.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Stopping systemd-timesyncd doesn't prevent it being restarted by a
different transaction within systemd. Disable the service instead during
the date test to ensure it can't be restarted.
(From OE-Core rev: 3dd4e637c11abdd6341a3e0c6b67639d3d703862)
Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
Acked-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
The fetcher GITDIR variable wase dropped a while back, drop the
obsolete reference to it (thanks Robert Day).
(From OE-Core rev: de035e687e26cef96e9b737c47bfc291bdfbea48)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
Poking changes into config_data and expecting them to appear in the recipe
is a bad idea, place the data in recipedata directly instead.
(From OE-Core rev: 191dd811900ace0e0af2e97221e10461fae0d9bd)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
bitbake dropped support for this piece of functionality (the test was
the only user), drop the test too.
(From OE-Core rev: 9ba0708e34eb038dc3ea5a877a5837c534cf165f)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
| |
(From OE-Core rev: 7bd0bb37ed98b7b8c2ce05f1434fe5ff12f8efc9)
Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
Printing a warning for something which is harmless just causes the
people monitoring the autobuilder more work. Silently ignore this race.
(From OE-Core rev: 2246c8d2466d3876fd1b27fd1943aa4bbf28e14e)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove the redundant comma to fix the json decode error:
$ resulttool manualexecution ../meta/lib/oeqa/manual/bsp-hw.json
Traceback (most recent call last):
[snip]
File "/usr/lib/python3.6/json/decoder.py", line 357, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 948 column 1 (char 39810)
(From OE-Core rev: 483c2d318c63fc2927680c1613d60864bb6287ab)
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When booting weston images this error is seen commonly, but Qemu boots
the image fine, session seat error is thrown by libweston perhaps using
--seat option or setting XDG_SEAT variable in weston.ini could fix it
[YOCTO #13828]
(From OE-Core rev: 1f9d36722132c93c19651ea59062b3d5be01bb72)
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add the option --json-result-dir to oeqa core context to enable
testresults.json creation for test runs via testexport.
Eg. oe-test runtime --json-result-dir .
(From OE-Core rev: 9d8edf33d1f5d89b310923b0aa3cc967317c7c49)
Signed-off-by: Stefan Kral <sk@typedivision.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
| |
(From OE-Core rev: bf959e6fd175d0841a1c042bf925c54200bea3d4)
Signed-off-by: Stefan Kral <sk@typedivision.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
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)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On the system whose cpu doesn't support rdrand,
there comes below message when start rngd service
#systemctl status rngd
[snip]
Feb 25 05:08:14 qemux86-64 rngd[133]: [rdrand]: Initialization Failed
[snip]
Actually the failed message doesn't matter as it
only indicates one entropy source as rdrand fails
to initialize and won't affect rngd function.
So add to ignore the failure message to fix below
error during do_testimage:
NOTE: ======================================================================
NOTE: FAIL: test_parselogs (parselogs.ParseLogsTest)
NOTE: ----------------------------------------------------------------------
NOTE: Traceback (most recent call last):
File "/buildarea/layers/oe-core/meta/lib/oeqa/core/decorator/__init__.py", line 36, in wrapped_f
return func(*args, **kwargs)
File "/buildarea/layers/oe-core/meta/lib/oeqa/runtime/cases/parselogs.py", line 370, in test_parselogs
self.assertEqual(errcount, 0, msg=self.msg)
AssertionError: 1 != 0 : Log: /buildarea/tmp/work/qemux86-64-wrs-linux/wrlinux-image-std/1.0-r5/target_logs/daemon.log
Central error: 2020-03-06T09:45:12.774286+00:00 qemux86-64 rngd[134]: [rdrand]: Initialization Failed
Reference: https://github.com/nhorman/rng-tools/pull/84
(From OE-Core rev: 09c4f9068858bf59eb60584a497f987bdd1e196e)
Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
Add missing import os statement to the oeqa runtime ptest.py
(From OE-Core rev: e41c92c60694052c8292c1ea6b3d0b427aafafd7)
Signed-off-by: Stefan Kral <sk@typedivision.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This will be needed for making xz compression more deterministic,
as xz archives are created differently in single- vs multi-threaded
modes.
This means that due to bitbake's default of using as many threads
as there are cores in the system, files compressed with xz
will be different if built on a multi-core system compared to
single-core systems.
Allowing cpu_count() here to return a lower bound, will allow
forcing xz to always use multi-threaded operation.
(From OE-Core rev: c6dda204e15c5b27559f7617b18a7b3ce604e2f8)
Signed-off-by: André Draszik <git@andred.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Removed ffsb copying file and associated runtest file fs_ext4
(both removed in this release).
Added LIBS=-lfts for MUSL.
Removed patches (accepted upstream)
* 0001-mkswap01.sh-Add-udevadm-trigger-before-swap-verifica.patch
* 0001-testcases-fix-an-absent-format-string-issue.patch
* 0001-nm01-Remove-prefix-zeros-of-the-addresses-output-by-.patch
Merged patches
* 0006-rt_tgsigqueueinfo-disable-test-on-musl.patch
(into 0001-build-Add-option-to-select-libc-implementation.patch as they
touch the same files)
Refreshed patches (some tests have been fixed for musl)
* 0001-Add-more-musl-exclusions.patch
* 0001-build-Add-option-to-select-libc-implementation.patch
* 0002-kernel-controllers-Link-with-libfts-explicitly-on-mu.patch
IMHO this one shouldn't be needed not, but CI still fails without it
Updated status
* 0008-testcases-network-nfsv4-acl-acl1.c-Security-fix-on-s.patch
* 0001-syscalls-Check-for-time64-unsafe-syscalls-before-usi.patch
(From OE-Core rev: 62e2063698477a13c55ae370451e52a2f1e18e45)
Signed-off-by: Petr Vorel <petr.vorel@gmail.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
We've found we need a way to cause a change in signatures and move
to a new hash 'namespace' with hashequiv. This introduces a variable
which allows us to do this.
(From OE-Core rev: 1c2d5aeae2fa2dfc16bc60b6cf0b310f826337fd)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This can be useful with a more specific, targeted and robust set of ptest
packages; the benefit is that ptest regressions are caught as they happen
and can be more easily traced to changes that caused them.
The existing AB ptest image continues to be expected to fail, my observation
of the AB runs is that the full set of ptests is not robust enough
(particularly around socket/network related tests) and sporadically fails
in random places. This can probably be addressed by making ptests exclusive
to a worker (e.g. there is no other workload happening at the same time as
ptests).
(From OE-Core rev: 102afcc7ea7d7673183f272a29ab233084ad168b)
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
I spotted this by noticing ptests started to unexpectedly pass,
which shouldn't happen yet.
(From OE-Core rev: 1cd6e9a8fdfef927916c6cea2371fc0430b1ffdf)
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On the autobuilder a ptest log with 2.1 million lines took around 18 hours to
process. This is clearly crazy.
We can tweak the processing code to:
a) Stop repeatedly joining large strings together (append to a list instead)
b) Use one startswith expression instead of multiple re.search() operations
With this change it takes 18 hours down to around 12s.
[YOCTO #13696]
(From OE-Core rev: 01c9f40b979e36a53e789a6bedd89b6d9557dce3)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
Now selftest is using its own copied build directory, we can stop worrying about
copying files around as backup, and drop the SIGTERM handler to try and restore
them, simplifying the code.
(From OE-Core rev: b8ea8a910267fee4bb9e57f24ba829064e22d016)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
non-concurrent selftest
Currently oe-selftest reuses the current build directory and the concurrent
version run with -j does not.
Standardise and use a separate new build directory in both cases. This will lead
to simpler code and more reliable user run tests.
(From OE-Core rev: 50238b0717b04e0a1fa69d618e8c8aa8445a80b0)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
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)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Yocto Bug: https://bugzilla.yoctoproject.org/show_bug.cgi?id=13663
Prior to this fix, the try/except block in OEScriptTests' setUpClass
did both the import and the raise unittest.SkipTest for the
subsequent OEPybootchartguyTests. The consequence of the this meant
that, when cairo was not available on the test host, the raise was
counted only once as a class setup issue, instead of once for each
of the tests to be run, resulting in incorrect skip counts in the
test results.
Instead of raising unittest.SkipTest in setUpClass, the more
proper method is to use the unittest.skipUnless method along with
importlib.util.find_spec to check for the presence of the
python3-cairo module. This allows the entire class to be skipped
if cairo is not present, while also correctly passing along the
skip state for each of the class's tests, and avoiding the UNKNOWN
results to appear in cases where the -j option was provided to
oe-selftest, but the tests were still skipped.
(From OE-Core rev: 10c2216cb6fb61c74babd8bd17cb3481754b7475)
Signed-off-by: Trevor Gamblin <trevor.gamblin@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
Includes jquery in the output directory to make the diffoscope output
easier to navigate
(From OE-Core rev: ff7c386455848e497ef40f9fee2be87d5171e203)
Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
see: https://bugzilla.yoctoproject.org/show_bug.cgi?id=13663
When running oe-selftest in concurrency mode (e.g. with oe-selftest
--run-tests oescripts.OEPybootchartguyTests -j 4), if a skip occurred
during setUpClass() rather than within individual tests, the entire
suite would show "UNKNOWN" as each test's result. This is because
subunit doesn't know how to handle skips outside of individual tests.
An example of where this occurs is when running the above call to
oe-selftest in concurrency mode on a host machine that does not have
python3-cairo installed.
Patch subunit inside concurrencytest.py to provide a method called
outSideTestaddSkip, which will allow subunit to correctly detect the
skip in setUpClass().
(From OE-Core rev: 9b8734b584d6e8d9c32ff2a721b29f3f3e61cca7)
Signed-off-by: Trevor Gamblin <trevor.gamblin@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Corrections:
- environment
- accommodate
- conversion
- compatible
(From OE-Core rev: 9797d3b45b4e1b9d77f0f2ee299c17b48d8d3cf6)
Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
The test is checking that weston is able to start.
(From OE-Core rev: 57700767f90eea8f2b78187c42581aca42d50bbf)
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I am not sure if this has ever worked, but uvesafb is a really
outdated (VBE from the 1990s), awkward (needs v86d) and limited
(no support for high resolutions) way to do it.
The specific reason 640x480-32 was introduced (ages ago) was
to force 32 bit mode with vmware driver, as 16bit had rendering issues.
The modern, supported option is video=... kernel parameter documented here:
https://wiki.archlinux.org/index.php/kernel_mode_setting#Forcing_modes_and_EDID
https://github.com/torvalds/linux/blob/master/Documentation/fb/modedb.rst
which can be passed directly to runqemu and doesn't require special
kernel modules.
Sato under X will continue to use 640x480 as that is hardcoded into
xorg.conf under qemu.
(From OE-Core rev: 1cf26f69fd89b43be24cd1232c43e5050b9d718a)
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
The APPEND is an optional variable, so add it to the optional variables
list to make the wic selftest happy.
(From OE-Core rev: 7c8b3a1b920fd4cc1598357985eef0e5e0e0ac79)
Signed-off-by: Kevin Hao <kexin.hao@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
If there are differing packages and they are being saved for review,
automatically run diffoscope on them and include the output in the saved
output. The output is currently done in HTML format since these are
typically published on a webpage by the autobuilder.
(From OE-Core rev: 6e1d5e8b58f0940ba6dfd99536159dd974e6f24c)
Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
since the versions of autotools might differ on target and build host, plus difference in
timestamps for configure and system can result in reconfigure lets avoid
that by disabling maintainer mode
Avoids
error: newly created file is older than distributed files!
[YOCTO #13779]
Suggested-by: Andre McCurdy <armccurdy@gmail.com>
(From OE-Core rev: 3dc4e27e7633ce3ca6b9647810d0996bdee48771)
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
booting processes to be tested
The current runtime infrastructure contains hardcoded values which Ill refer to
as patterns, these patterns are either searched through or sent via the serial
terminal to communicate between HOST and TARGET.
These patterns are required since they allow us to check when a device has
finished booting, to log in, and to check whether a command sent from our tests
has returned, this way we are able to check both the status of the commands that
were sent along with its output.
The testing process goes somewhat as follows:
1. Launch QEMU and start booting.
2. Check when the device has booted by looking for the pattern login:.
3. Log in as the root user (default for our images).
4. Check that we were able to log in succesfully.
5. Start running the runtime test cases defined by TEST_SUITES.
6. One of such test cases could send a command to the QEMU target.
7. Check whether that command returned.
8. Check its output and status, return whether the test case passed or failed.
This patch allows this set of patterns to be defined instead of being hardcoded,
but it also automatically sets the defaults that we have been using in the past
if they have not been manually defined, for this reason, the patch is less
invasive and should not affect in any way how tests are currently being run.
Cases that can be enabled with this patch:
- A customized image that does not use the root user (or maybe we want to check
what happens if we dont use the root user).
- An image where the PS1 env variable has been modified, and the prompt pattern
wouldnt match the default.
- Baremetal applications, which do not follow the conventional way of booting
Linux and would probably not show a prompt for a user to log in, same applies
for testing bootloaders.
- poky-tiny: Using DISTRO=poky-tiny and an image such as the core-image-tiny
from meta-intel, which boots directly to RAM, and does not show a log in prompt
since it does not contain a conventional init process.
The code itself contains comments that should be self explanatory but here is an
example on how these patterns can be defined in a hypothetical case where we
want to run test cases as the webserver user instead:
TESTIMAGE_BOOT_PATTERNS = "send_login_user search_login_succeeded"
TESTIMAGE_BOOT_PATTERNS[send_login_user] = "webserver\n"
TESTIMAGE_BOOT_PATTERNS[search_login_succeeded] = "webserver@[a-zA-Z0-9\-]+:~#"
The variable TESTIMAGE_BOOT_PATTERNS defines which patterns to override when
used to communicate with the target when booting, anyone familiar with the
PACKAGECONFIG syntax should have no trouble setting these.
Other patterns would still be set up as default, e.g.
search_reached_prompt would still be login:
The accepted flags for TESTIMAGE_BOOT_PATTERNS are the following:
search_reached_prompt, send_login_user, search_login_succeeded,
search_cmd_finished.
They are prefixed with either search/send, to differentiate if the pattern is
meant to be sent or searched to/from the target terminal.
A working example of this code that falls under the baremetal case mentioned
above along with a test case is present on the meta-freertos layer, which tests
an RTOS image built with OpenEmbedded and automatically runs a test case on it
after booting such image:
As usual, INHERIT += "testimage" needs to be present on local.conf
$ bitbake freertos-demo -c testimage
RESULTS:
RESULTS - freertos_echo.FreeRTOSTest.test_freertos_echo: PASSED (2.00s)
SUMMARY:
freertos-demo () - Ran 1 test in 2.006s
freertos-demo - OK - All required tests passed (successes=1, skipped=0,
failures=0, errors=0)
(From OE-Core rev: 3ab2cbfeff371e8791b031a2852eeef80101a831)
Signed-off-by: Alejandro Hernandez Samaniego <aehs29@gmail.com>
Signed-off-by: Alejandro Hernandez Samaniego <alejandro@enedino.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
commmit 6cde67d0a84 enables the use of qemurunner on machines that
only have a single serial port, but still sets the default value
as serial_ports=2 if not provided.
The testimage class does not call qemurunner with a serial_ports
argument, hence always defaulting to two.
Pass the serial_ports argument from the testimage class to allow
tests to run on QEMU machines with a single serial port.
(From OE-Core rev: a50d0163770f0b405a8de8a8a9cccd48c1de4112)
Signed-off-by: Alejandro Hernandez Samaniego <alejandro@enedino.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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: eadb899e23b18eb9eaff145c3bf5b20fb417c3e8)
Signed-off-by: Trevor Gamblin <trevor.gamblin@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
cpio 2.12 was released in 2015 and might have used older autotools
which could result in errors like
https://bugzilla.yoctoproject.org/show_bug.cgi?id=13779
Bumping to 2.13 will help in matching the tool versions
A good change on top would be to run
aclocal -I .; autoheader; autoconf; automake --add-missing -c
before running configure step perhaps
[YOCTO #13779]
(From OE-Core rev: 84eb1dc4fe8a11cd2d05b703070a6fb6de05b873)
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
Due to recent changes to the tune, in order to match config.guess, the name
of the big-endian microblaze architecture was changes to 'microblaze'.
(From OE-Core rev: 6f6a6bbac684ead3fe6d070d61f17c2f611a2c87)
Signed-off-by: Mark Hatle <mark.hatle@kernel.crashing.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
See bug https://bugzilla.yoctoproject.org/show_bug.cgi?id=13632
Autobuilder tests occasionally fail, reporting that a new logfile
could not be created. While this failure did occur multiple times, it
could not be manually reproduced. However, there are issues with the
implementation of the logrotate.py script that can be fixed. These
changes will help make the failures clearer, should they continue to
occur.
Previously, the test_2_logrotate test would, after running the
logrotate tool, use "ls -al $HOME/logrotate_dir | wc -l" to count
the number of files in the rotation directory and determine if the
rotation was successful. The test to see if there are at least three
files is problematic, because depending on the version of ls used, it
may report the target value of 3 even when there are only hidden files
in the directory, potentially reporting a pass for the test when it
should actually fail. An example with coreutils:
root@qemux86-64:~# ls -al emptydir/
total 2
drwxr-xr-x 2 root root 1024 Jan 14 19:50 .
drwx------ 3 root root 1024 Jan 14 19:50 ..
root@qemux86-64:~#
Where "total" is the number of blocks used. Compare with busybox ls:
root@qemux86-64:~# ls -al emptydir/
drwxr-xr-x 2 root root 1024 Jan 14 19:54 .
drwx------ 3 root root 1024 Jan 14 19:54 ..
root@qemux86-64:~#
Instead of using ls to verify that a certain number of files exists
in $HOME/logrotate_dir, the tests have been changed to rotate two
specific logs: the log for wtmp and a new logrotate_testfile created
during the second test. Both tests check that the logs are correctly
rotated into $HOME/logrotate_dir by using find and grep on the
expected filename (e.g. "wtmp" when rotated becomes "wtmp.1", so we
check to see that wtmp.1 is present in $HOME/logrotate_dir). In
addition, should the test fail, the output from logrotate -vf is
included in the test log to aid debugging. It has also been seen that
in some cases, the logrotate test fails because the /var/log/wtmp file
is not yet present. Since the objective of the test is to check the
logrotate functionality and not the presence of certain log files,
test_logrotate_wtmp uses the touch command to help ensure that the
file is present before the call to logrotate is issued.
Finally, note that while the autobuilder failures that this patch
addresses were only seen during core-image-full-cmdline tests, these
changes were successfully tested on core-image-minimal and
core-image-sato with the manual addition of logrotate and openssh-sshd
to the images.
(From OE-Core rev: b9392403e96c6d880de844b44da2c7300fcf411c)
Signed-off-by: Trevor Gamblin <trevor.gamblin@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|