Commit Graph

238 Commits

Author SHA1 Message Date
Richard Purdie e5cb267922 sstatesig: Anchor inherits class tests
This avoids a nasty sstate hash corruption issue where the
fact the testimage bbclass was inherited meant that the checksum
changed due to testimage.bbclass being confused with image.bbclass.

This patch anchors the bbclass names to avoid this confusion.

(From OE-Core master rev: 943a75a4f3b6877e4092dae14b59b7afef8cad3d)

(From OE-Core rev: 71b15a41652e280aca2a451073a83a25fb4e6f50)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-04-11 12:02:50 +01:00
Richard Purdie 8d0f411fdb sstatesig.py: Fix image regeneration issue
With the "ABI safe" recipes, we've been excluding those from signatures. This
is fine in the general case but in the specific case of image recipes it breaks.

A good test case is the interfaces file. Editting this causes init-ifupdown
to rebuild but not an image containing it (e.g. core-image-minimal).

We need to ensure the checksums are added to the image recipes and this change
does that.

(From OE-Core master rev: fd085f15e7cd093953f974f69277e130174d551d)

(From OE-Core rev: 946ec90c5de1faa18c899e9b45efedc3d47b93bd)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-04-11 12:02:49 +01:00
Richard Purdie 98bd952a5b Revert "buildhistory_analysis: fix error when comparing image contents"
This reverts commit 5b616aa7b6.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-04-04 16:16:50 +01:00
Jacob Kroon 9797e78a9b meta/lib/oe/terminal.py: Don't pass non-supported '--disable-factory' flag to gnome-terminal
By default, all GNOME terminals share a single process,
reducing memory usage.  This can be disabled by starting gnome-terminal
with the --disable-factory option

However, gnome-terminal in Fedora 20 does no longer support the
'--disable-factory' flag, so remove it. As the support for 'mate' terminals was
added as a copy of the gnome code in 8cc078a9c679845464c59028f584d7aba098cc1f,
remove the flag here aswell.

(From OE-Core master rev: e8dca725ed8211a874472300a3ed50e494039ab9)

(From OE-Core rev: b3c051aecde0c0662b352eb789ed276ef00e626f)

Signed-off-by: Jacob Kroon <jacob.kroon@mikrodidakt.se>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-02-09 11:04:15 +00:00
Paul Eggleton 5b616aa7b6 buildhistory_analysis: fix error when comparing image contents
OE-Core commit b7de1eaac9eed559b2d68058f5de67de74a6cb58 added an extra
argument to the compare_dict_blobs() function but missed adding the
argument to one call to compare two versions of the image-info.txt file.

(From OE-Core master rev: 24a45d752c3e3d0d8b59c040355e4fe7de22b041)

(From OE-Core rev: a51d96c44e6feac8322284c54bfc01ef598f8821)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-12-12 17:00:19 +00:00
Richard Purdie bf19a8617d lib/oe/path: Fix copytree functions for tar 1.27
tar version 1.27 returns:

tar: --same-order option cannot be used with -c

with the commandlines we have been using. We can remove the -s option (which
is --same-order) to remove the error.

(From OE-Core rev: 69c26e795c117aabfaf313abbfd10e70ede633d9)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-10-14 16:55:21 +01:00
Stefan Stanacar 41f88ee1db lib/oeqa/runtime: ping: wait for 5 echo replies
Instead of considering that ping test passed after 1 reply,
wait for at least 5 consecutive replies in 60 seconds (which should
be enough time for connman to reconfigure the interface in systemd
images and help with the fake ssh/tests fails.)

(From OE-Core rev: 6fd19a9df0ad25b2822f12e2c3a97f1b71068d4e)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-26 16:37:55 +01:00
Stefan Stanacar ad77d10386 lib/oeqa/runtime: cleanup and improve output readability for some tests
- move everything in the same test. setUp/tearDown aren't quite
the right thing here, everything it's part of the same test. (and
it get's confusing when ssh fails)

ldd:
   - change test name and add output to error message

vnc:
   - remove unnecessary check as there is no point in doing
both ps and netstat. Also improve error output a bit.

(From OE-Core rev: 2f91bb438cfcdd0a40daed5902b6e98fc0aee67f)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-22 12:19:33 +01:00
Stefan Stanacar f3ab2fc731 lib/oeqa/utils: sshcontrol: log how long the last command take
It might be useful for debugging to have in the ssh log
the number of seconds a command has run.

(From OE-Core rev: 48b9e45b9716130b015ae2ab7398d6aa243933dc)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-22 12:19:33 +01:00
Ross Burton 4a224d31c8 qemurunner: disable grabs in automated testing
Use the new QEMU_DONT_GRAB environment variable to disable grabs,
finally/hopefully solving the random hangs that the autobuilder has been hitting
for a while.

[ YOCTO #5131 ]

(From OE-Core rev: 32f9575a565f350649264c11eceba8311584b0fd)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-18 17:52:04 +01:00
Saul Wold 14fee32867 oeqa/runtime/smart: Increase timeout to 1500 test
(From OE-Core rev: a99edb5552839fd50326dd3aa4ee2f36f6026882)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-17 19:34:55 +01:00
Stefan Stanacar 214bb6828e lib/oeqa/runtime: timeout increases
Increase the timeout for smart commands as under load for qemumips
it's still to small. Also give ping more time fixing a potential
timeout for sato systemd.

(From OE-Core rev: daa3ad5807f6fc0d15b9310937d07a16edac6d22)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-14 08:21:00 +01:00
Richard Purdie 8ebe7be3d9 bitbake.conf/package: Collapse PKGDATA_DIR into a single machine specific directory
Currently we have a hierarchy of pkgdata directories and the code has to put together
a search path and look through each in turn until it finds the data it needs.

This has lead to a number of hardcoded paths and file globing which
is unpredictable and undesirable. Worse, certain tricks that should be
easy like a GL specific package architecture become problematic with the
curretn search paths.

With the modern sstate code, we can do better and construct a single pkgdata
directory for each machine in just the same way as we do for the sysroot. This
is already tried and well tested. With such a single directory, all the code that
iterated through multiple pkgdata directories and simply be removed and give
a significant simplification of the code. Even existing build directories adapt
to the change well since the package contents doesn't change, just the location
they're installed to and the stamp for them.

The only complication is the we need a different shlibs directory for each
multilib. These are only used by package.bbclass and the simple fix is to
add MLPREFIX to the shlib directory name. This means the multilib packages will
repackage and the sstate checksum will change but an existing build directory
will adapt to the changes safely.

It is close to release however I believe the benefits this patch give us
are worth consideration for inclusion and give us more options for dealing
with problems like the GL one. It also sets the ground work well for
shlibs improvements in 1.6.

(From OE-Core rev: 1b8e4abd2d9c0901d38d89d0f944fe1ffd019379)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-14 08:21:00 +01:00
Paul Eggleton 6670be71f7 bitbake.conf: include machine name in DEPLOY_DIR_IMAGE
This allows a clean seperation between image outputs from different
machines, and makes it possible to have convenience symlinks to make
the output ready to deploy.

This did require some surgery in runqemu; if explicit paths to the image
and kernel are not supplied then DEPLOY_DIR_IMAGE needs to be determined
from bitbake or set in the environment. However the script does try to
avoid requiring it unless it really is needed. Corresponding changes
were made in the automated testing code as well.

Based on an RFC patch by Koen Kooi <koen@dominion.thruhere.net>

(From OE-Core rev: 7e90261aec61f79680b5eaeaf5b18c7b795412a4)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-14 08:21:00 +01:00
Stefan Stanacar 01135ee6f2 lib/oeqa/runtime: smart: limit channel add to useful ones
Don't add inappropiate channels on the target.
This happens when building two different machines in the
same dir and then running the tests for each machine.

(From OE-Core rev: 9e4e475b598f6b9bd2b653c72a1c1d5bd5c0b8c9)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-11 23:31:00 +01:00
Richard Purdie 9b84fc7cc2 lib/oeqa/qemurunner: Use a timeout in select() call
A 0 value to select.select() immediately returns with no timeout. This was
pegging the cpu at 100% for the python process which was bad and may be
contributing to some of the timeout problems.

Profile from -P of a core-image-minimal before:

    97526792 function calls (97525652 primitive calls) in 45.189 seconds

and after:

       50204 function calls (49064 primitive calls) in 17.318 seconds

Saving 97.5 million function calls has to be good :)

(From OE-Core rev: c0551436974d179df23418567f18a082830380f6)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-06 23:04:51 +01:00
Stefan Stanacar 41d1c2d630 lib/oeqa/runtime: add basic scanelf test
This uses scanelf from the pax-utils package and scans the binaries in PATH
for TEXTREL and RPATH information. For a sato image with pax-utils installed
it shows no output (which is good).

(From OE-Core rev: 629099ad66f5fa2814e5f7908b426149e8978e43)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-06 23:04:50 +01:00
Mihai Lindner faed110e66 oeqa/runtime/scp: replace dd call
Use a file object to generate a our test file instead of calling `dd`;
removes dd's output from testimage.log, keeps unittest output clean.
Also remove unused imports.

(From OE-Core rev: 6ac48ffbab29a37b0eada533191878aeae3c91f0)

Signed-off-by: Mihai Lindner <mihaix.lindner@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-06 23:03:23 +01:00
Mihai Lindner fbb3e5e11f oeqa/utils/sshcontrol: tweak ssh options
Add ssh_options to be used, the same, by ssh and scp:
Decrease LogLevel to ERROR, to suppress warnings (e.g. ssh host
verifications, two warnings in case of having openssh with hpn patches);
We no longer presume that the first line is a warning.

(From OE-Core rev: 1f18d04eec03e586134b6d77ca1c6151c22353dd)

Signed-off-by: Mihai Lindner <mihaix.lindner@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-06 23:03:23 +01:00
Mihai Lindner f6fed84380 oeqa/oetest: oeRuntimeTest: enable long messages
Set longMessage to True for all tests derived from oeRuntimeTest, in
order to have somewhat info on assertions with cryptic or no messages.

(From OE-Core rev: e5196ebd6c652431a3b80cdc9f60b752401314f4)

Signed-off-by: Mihai Lindner <mihaix.lindner@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-06 23:03:23 +01:00
Stefan Stanacar e3bc93c2eb lib/oeqa/runtime: smart: serve repo on host ip only and increase timeout
Don't start the http server on 0.0.0.0, listen on host ip (end of tap interface) only.
Also use the timeout option (default is 300s for ssh commands) for all the commands
run in this module (mostly because smart update timeouts on mips).

(From OE-Core rev: 8c272641ef3e8410f331ca4133d28dea8f36e4f4)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-03 19:57:38 +01:00
Richard Purdie 554c892ccf meta: Don't use deprecated bitbake API
These have been deprecated for a long time, convert the remaining
references to the correct modules and prepare for removal of the
compatibility support from bitbake.

(From OE-Core rev: 6a39835af2b2b3c7797fe05479341d71a3f3aaf6)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-01 15:51:42 +01:00
Stefan Stanacar efff0d5504 lib/oeqa/runtime: ping: fix ping false fail
We run the ping test as soon as we reach the login prompt.
But sometimes (seen in sato systemd) we end up with link down/link up stuff like:

    qemux86-64 login: IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
    e1000: eth0 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX
    IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready

The logic behind ping -w 30 -c 1 was to wait at most 30 seconds
for at least one reply,  but there is a catch: reply doesn't seems
to be echo reply but any reply (non-reply means loss not network error)
ping's man page:
    -w deadline
              Specify  a  timeout, in seconds, before ping exits regardless of
              how many packets have been sent or received. In this  case  ping
              does  not  stop after count packet are sent, it waits either for
              deadline expire or until count probes are answered or  for  some
              error notification from network.

Just when the link up/link down happens ping returns:
    From 192.168.7.1 icmp_seq=1 Destination Host Unreachable
    --- 192.168.7.2 ping statistics ---
    1 packets transmitted, 0 received, +1 errors, 100% packet loss, time 0ms

and exits sooner than the 30 seconds timeout.

This patch should do what was originally intended (wait at most
30 seconds for at least one reply).

(From OE-Core rev: 56d144fd22d37189e49cdf3032afb00f0be469c6)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-30 18:08:05 +01:00
Stefan Stanacar 8f32af94c0 lib/oeqa/runtime: syslog: fix test for logger in case of systemd
Recently syslog behaviour changed for systemd images (log
it's in a buffer not in /var/log/messages), account
for the new stuff.

(From OE-Core rev: 32576c4cc1621fa3013eac66c7caaa1e1fd14995)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-30 16:23:47 +01:00
Stefan Stanacar 249dc825a0 lib/oeqa/utils: qemurunner: fix when runqemu errors out
When qemu doesn't start or runqemu errors out
(some wrong option passed or sudo needs a password for setting tap) we
want to display the output but oe-core commit 9de7fe11967576f4a8b24e653c6b9a02e5f6d85b/
poky commit 51588936d4
changed the kill method and broke this code, so let's fix it.

(From OE-Core rev: 923d4bd548911caa0b419c10905895af1e8e7026)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-30 16:23:47 +01:00
Stefan Stanacar c52981c9bc lib/oeqa: move skeletoninit.py where it belongs
OE-core commit fcc59cbcdb1550489d372edf9f465efa7165245f /
poky commit 748ddc39e5 added a new test, but
in the wrong location.
I took the patch from Alex's branch but renamed it from meta/lib/oeqa/runtime/skeleton.py to meta/lib/oeqa/skeletoninit.py before sending. This was
unintentional, it should have been under meta/lib/oeqa/runtime.

(From OE-Core rev: f12c346ef48cb44be2e356e4cf4f28d015c3f507)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-30 16:23:44 +01:00
Stefan Stanacar 5fba9d8c6c classes/testimage: add support for finding tests in other layers
A layer can add tests in lib/oeqa/runtime (provided it extends BBPATH as
normal) and enable them with TEST_SUITES_append = " testname". Test
module names shouldn't collide though.

(From OE-Core rev: e1e347a2d509303e1c566450b0f2b485d3d6629f)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-28 23:36:08 +01:00
Stefan Stanacar 4e62e9cb76 lib/oeqa/runtime: remove some unnecessary checks from setUpModule
These checks are unnecessary.
setUpModule is run when a module is loaded and we
shouldn't run commands on the target here, (plus if
ssh doesn't work we error out in setup multiple times, instead
of skipping the real test, which might depend on test_ssh).

(From OE-Core rev: 188acd0a75e188fd7c0d2979acaf13fd18b12106)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-28 23:36:08 +01:00
Stefan Stanacar 44c3f72684 lib/oeqa/runtime: smart: add checks for smart output
Sometimes smart throws:

    Committing transaction...
    Preparing...                    ######################################## [  0%]
       1:Removing psplash-default   ######################################## [100%]
    error: Couldn't fork %postun: Cannot allocate memory

and returns a 0 exit code (it thinks it succesfully removed the package,
when in reality it didn't), so we need to catch those specifically.

Also, sometimes output from download command is:
    Saving cache...http://192.168.7.1:49456/rpm/x86_64_x32/psplash-default-0.1+git0+afd4e228c6-r15.x86_64_x32.rpm
and that tricks our smart download test, so use a regex there.

(From OE-Core rev: 2ac7783e04f5e8e6005f967e1a6dd65d2fc6a19a)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 16:29:18 +01:00
Stefan Stanacar a855180fe6 lib/oeqa/runtime: multilib: fix typo
The check was obviously wrong and it surfaced
with the recent change in behaviour for skipping tests.

(From OE-Core rev: 4a14535cd493cb2bdd46b2a5f2a1cd2b38161f0a)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 16:29:18 +01:00
Stefan Stanacar 2dfc0e1cc7 lib/oeqa: change behaviour for unskippable tests
When a test module wants to be skipped because it doesn't
apply to the image but it was nevertheless a required
test (one in TEST_SUITES), we issued an warning that it
was a required test and went on with running the module.
Usually all tests in the module failed (e.g gcc tests on a non-sdk image),
but this allowed us to know that something went wrong with the image
(some package/feature didn't make it).

However, instead of just issuing an warning and running the tests
it's better to throw an exception. The traceback will tell us what's wrong,
and we don't run every single test method.
Output will look like this:
--snip--
| NOTE: Test modules  ['oeqa.runtime.ping', 'oeqa.runtime.ssh', 'oeqa.runtime.gcc']
| NOTE: Found 5 tests
| test_ping (oeqa.runtime.ping.PingTest) ... ok
| test_ssh (oeqa.runtime.ssh.SshTest) ... ok
| ERROR
|
| ======================================================================
| ERROR: setUpModule (oeqa.runtime.gcc)
| ----------------------------------------------------------------------
| Traceback (most recent call last):
|   File "/mnt/back/yocto/poky/meta/lib/oeqa/runtime/gcc.py", line 8, in setUpModule
|     skipModule("Image doesn't have tools-sdk in IMAGE_FEATURES")
|   File "/mnt/back/yocto/poky/meta/lib/oeqa/oetest.py", line 108, in skipModule
|     "\nor the image really doesn't have the requred feature/package when it should." % (modname, reason))
| Exception:
| Test gcc wants to be skipped.
| Reason is: Image doesn't have tools-sdk in IMAGE_FEATURES
| Test was required in TEST_SUITES, so either the condition for skipping is wrong
| or the image really doesn't have the requred feature/package when it should.
|
| ----------------------------------------------------------------------
| Ran 2 tests in 1.036s
|
| FAILED (errors=1)
| NOTE: Sending SIGTERM to runqemu
--snip--

(From OE-Core rev: fd51cecf8b258d9f839a0ecebde69d09f75dc468)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:21 +01:00
Mihai Prica d7077bc8e5 lib/oeqa/runtime: add iptables, cvs and sudoku projects build tests on target
Downloads iptables/cvs/sudoku-savant sources and builds them on target.

(From OE-Core rev: df4568205c3a7e0b20c6299e29f96bd30560146b)

Signed-off-by: Mihai Prica <mihai.prica@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:21 +01:00
Mihai Prica c70bf6531c lib/oeqa/utils: targetbuild: Add helper class for building packages on target
This class can be used for test cases that configure
and build packages on target.

(From OE-Core rev: 4b15e82c4fcb0c40b0e316ef2050944eee4418ef)

Signed-off-by: Mihai Prica <mihai.prica@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:21 +01:00
Stefan Stanacar 51588936d4 lib/oeqa: make it possible to restart the target
Tweak QemuRunner so we can actually restart the
qemu target in a test (if we want more memory for example).
Also add a restart method to the base test class so that tests
can use it.

(From OE-Core rev: 9de7fe11967576f4a8b24e653c6b9a02e5f6d85b)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:21 +01:00
Mihai Lindner ecb21fd7f8 lib/oeqa/runtime: smart: add new smart tests
Add class to be inherited by smart tests, along with more basic tests and tests
using a rpm repository.

(From OE-Core rev: f6186b4204dcc421b4e616774315c8a2a77fb5c5)

Signed-off-by: Mihai Lindner <mihaix.lindner@linux.intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:21 +01:00
Mihai Lindner 2c83398940 lib/oeqa/utils: decorators: return the decorated method
Decorators should return whatever the decorated methods return.

(From OE-Core rev: c92513d6ff3f8f06d937a5cdf4d94708f27c3850)

Signed-off-by: Mihai Lindner <mihaix.lindner@linux.intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:21 +01:00
Mihai Lindner a9dab56e5d lib/oeqa/utils: qemurunner: save host IP address
Save host IP address to host_ip.
Read /proc/PID/cmdline on host to look for IPs of target and host;
instead of running 'ps'.
Also removed some extra empty lines from file.

(From OE-Core rev: 1fcf10db10fa36430e37c95c9fee27197e73f7a5)

Signed-off-by: Mihai Lindner <mihaix.lindner@linux.intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:21 +01:00
Mihai Lindner f16cc25bbc lib/oeqa/utils: new file: httpserver.py useful for serving files over HTTP to the target
It can be used by smart repo/channel tests to serve deploy_dir.

(From OE-Core rev: e38e18d6923cc3db50b56fa3fc64081fe4aa8669)

Signed-off-by: Mihai Lindner <mihaix.lindner@linux.intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:21 +01:00
Stefan Stanacar db7e4849c3 lib/oeqa/runtime: rpm: add install and erase tests
Copies to target rpm-doc file from deploy_dir
and tries to install and then remove that package.
rpm-doc was chosen because it's small, it only adds
a few files to target, and it's almost always found in
deploy_dir for images with package-management/rpm.

(From OE-Core rev: a2d2f2b7b111863d3c50dedded37aab813d9634f)

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:20 +01:00
Mihai Prica 3d30fd2eb0 lib/oeqa/runtime: add vncserver for target test
(From OE-Core rev: 56bc5d717b34563ed36c0618305e4ec5080c3a27)

Signed-off-by: Mihai Prica <mihai.prica@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:20 +01:00
Mihai Prica 5e1b0cb2e4 lib/oeqa/runtime: add adjust date and time test
(From OE-Core rev: ede300f44f1770b1e3e5c59f65cf5079379a2bc1)

Signed-off-by: Mihai Prica <mihai.prica@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:20 +01:00
Alexandru Palalau 0ecc510b92 lib/oeqa/runtime: add new scp test
Copies a 5MB to target using scp, more of an
network test than a scp one.

(From OE-Core rev: 2ec4a0686b9a91e56dfba3fa2e574c0c531508ff)

Signed-off-by: Alexandru Palalau <alexandrux.palalau@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:20 +01:00
Alexandru Palalau 4ea9e94f55 lib/oeqa/runtime: add new PAM support test
New test which verifies some usual commands functionality with PAM support

(From OE-Core rev: 06c7914e3354ff4e430a6b664f40e5a71e212761)

Signed-off-by: Alexandru Palalau <alexandrux.palalau@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:20 +01:00
Alexandru Palalau 748ddc39e5 lib/oeqa/runtime: add new skeletoninit test
New test which verifies the usage of skeleton init script available with meta-skeleton layer

(From OE-Core rev: fcc59cbcdb1550489d372edf9f465efa7165245f)

Signed-off-by: Alexandru Palalau <alexandrux.palalau@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:20 +01:00
Alexandru Palalau b91969e4f7 lib/oeqa/runtime: add new logrotate test
New logrotate test which verifies the log directory change in logrotate.conf.
Needs an image with logrotate installed.

(From OE-Core rev: 186d79a603b5cbf5a93e6f5dbba5f62ed8d4d8d8)

Signed-off-by: Alexandru Palalau <alexandrux.palalau@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:20 +01:00
Cornel Stoicescu 3b47a0a4bc lib/oeqa/runtime: add a test for ldd
This test checks that at least one path in RTLDLIST exists.

(From OE-Core rev: d53ffbf21a6b17f0f0537929a95a502958d82a09)

Signed-off-by: Cornel Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:20 +01:00
Cornel Stoicescu dfd627d7ac lib/oeqa/runtime: add test for perl
This test runs a perl script on the target and checks the output.

(From OE-Core rev: 95abdbf2d715c9e7e3368f5193167feb5efc6261)

Signed-off-by: Cornel Stoicescu <corneliux.stoicescu@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:20 +01:00
Alexandru Georgescu ec8aea9c01 lib/oeqa/runtime: add basic test for x32 images
Checks that an x86-64-x32 image has the right binaries.

(From OE-Core rev: da42e38b2bc4a606b717ac302cfc77aefb1a5795)

Signed-off-by: Alexandru Georgescu <alexandru.c.georgescu@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:19 +01:00
Christopher Larson 66eac2df0c oe.types: add 'path' type
- path normalization ('normalize' flag, defaults to enabled)
- existence verification for paths we know should exist ('mustexist' flag)
- supports clean handling of relative paths ('relativeto' flag)

(From OE-Core rev: a598242197312fa6d43179c283da2d0873de2919)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26 11:47:18 +01:00
Alexandru Palalau dbee00c9e9 lib/oeqa/runtime: add new systemd tests
New systemd runtime tests for enable/disable service, start/stop service and list services.

(From OE-Core rev: 6386dc718f85210c9b6b9f69878ec9a7847b78de)

Signed-off-by: Alexandru Palalau <alexandrux.palalau@intel.com>
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-13 23:06:00 +01:00