diff options
author | Stefan Stanacar <stefanx.stanacar@intel.com> | 2013-08-30 12:24:32 +0300 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2013-08-30 16:23:44 +0100 |
commit | c52981c9bcc66bdf1dae9c41b32f9079b1ecf304 (patch) | |
tree | 6ccbed8fc2586c532d9fcfcf789e066848ac965b /meta/lib/oeqa/runtime | |
parent | c03106dfbe88838b9d72a005969d388d3de8c6c4 (diff) | |
download | poky-c52981c9bcc66bdf1dae9c41b32f9079b1ecf304.tar.gz |
lib/oeqa: move skeletoninit.py where it belongs
OE-core commit fcc59cbcdb1550489d372edf9f465efa7165245f /
poky commit 748ddc39e56623f4e48987f0467f4722f6e162f2 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>
Diffstat (limited to 'meta/lib/oeqa/runtime')
-rw-r--r-- | meta/lib/oeqa/runtime/skeletoninit.py | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/meta/lib/oeqa/runtime/skeletoninit.py b/meta/lib/oeqa/runtime/skeletoninit.py new file mode 100644 index 0000000000..557e715a3e --- /dev/null +++ b/meta/lib/oeqa/runtime/skeletoninit.py | |||
@@ -0,0 +1,28 @@ | |||
1 | # This test should cover https://bugzilla.yoctoproject.org/tr_show_case.cgi?case_id=284 testcase | ||
2 | # Note that the image under test must have meta-skeleton layer in bblayers and IMAGE_INSTALL_append = " service" in local.conf | ||
3 | |||
4 | import unittest | ||
5 | from oeqa.oetest import oeRuntimeTest | ||
6 | from oeqa.utils.decorators import * | ||
7 | |||
8 | def setUpModule(): | ||
9 | if not oeRuntimeTest.hasPackage("service"): | ||
10 | skipModule("No service package in image") | ||
11 | |||
12 | |||
13 | class SkeletonBasicTest(oeRuntimeTest): | ||
14 | |||
15 | @skipUnlessPassed('test_ssh') | ||
16 | @unittest.skipIf("systemd" == oeRuntimeTest.tc.d.getVar("VIRTUAL-RUNTIME_init_manager"), "Not appropiate for systemd image") | ||
17 | def test_skeleton_availability(self): | ||
18 | (status, output) = self.target.run('ls /etc/init.d/skeleton') | ||
19 | self.assertEqual(status, 0, msg = "skeleton init script not found. Output:\n%s " % output) | ||
20 | (status, output) = self.target.run('ls /usr/sbin/skeleton-test') | ||
21 | self.assertEqual(status, 0, msg = "skeleton-test not found. Output:\n%s" % output) | ||
22 | |||
23 | @skipUnlessPassed('test_skeleton_availability') | ||
24 | @unittest.skipIf("systemd" == oeRuntimeTest.tc.d.getVar("VIRTUAL-RUNTIME_init_manager"), "Not appropiate for systemd image") | ||
25 | def test_skeleton_script(self): | ||
26 | output1 = self.target.run("/etc/init.d/skeleton start")[1] | ||
27 | (status, output2) = self.target.run(oeRuntimeTest.pscmd + ' | grep [s]keleton-test') | ||
28 | self.assertEqual(status, 0, msg = "Skeleton script could not be started:\n%s\n%s" % (output1, output2)) | ||