[gnome-continuous-yocto/gnomeostree-3.28-rocko: 8155/8267] oeqa/selftest/runtime: force empty root password, use helpers to access qemu
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-continuous-yocto/gnomeostree-3.28-rocko: 8155/8267] oeqa/selftest/runtime: force empty root password, use helpers to access qemu
- Date: Sun, 17 Dec 2017 07:15:17 +0000 (UTC)
commit c388d72c60a2476130aedcff5003a6ec0a671ad3
Author: Ross Burton <ross burton intel com>
Date: Tue Oct 31 20:59:09 2017 +0000
oeqa/selftest/runtime: force empty root password, use helpers to access qemu
(From OE-Core rev: 25a2db0c4e1c558cd14b2e7b7bce46f7d1ea02a7)
Signed-off-by: Armin Kuster <akuster mvista com>
Signed-off-by: Richard Purdie <richard purdie linuxfoundation org>
meta/lib/oeqa/selftest/cases/runtime_test.py | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/meta/lib/oeqa/selftest/cases/runtime_test.py b/meta/lib/oeqa/selftest/cases/runtime_test.py
index 7d105f2..7ce81c3 100644
--- a/meta/lib/oeqa/selftest/cases/runtime_test.py
+++ b/meta/lib/oeqa/selftest/cases/runtime_test.py
@@ -1,5 +1,6 @@
from oeqa.selftest.case import OESelftestTestCase
from oeqa.utils.commands import runCmd, bitbake, get_bb_var, get_bb_vars, runqemu
+from oeqa.utils.sshcontrol import SSHControl
from oeqa.core.decorator.oeid import OETestID
import os
import re
@@ -243,7 +244,7 @@ postinst-delayed-t \
with self.subTest(init_manager=init_manager, package_class=classes):
features = 'MACHINE = "qemux86"\n'
features += 'CORE_IMAGE_EXTRA_INSTALL += "%s %s "\n'% (rootfs_pkg, boot_pkg)
- features += 'IMAGE_FEATURES += "ssh-server-openssh"\n'
+ features += 'IMAGE_FEATURES += "empty-root-password ssh-server-openssh"\n'
features += 'PACKAGE_CLASSES = "%s"\n' % classes
if init_manager == "systemd":
features += 'DISTRO_FEATURES_append = " systemd"\n'
@@ -262,6 +263,6 @@ postinst-delayed-t \
testcommand = 'ls /etc/' + fileboot_name
with runqemu('core-image-minimal') as qemu:
- sshargs = '-o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no'
- result = runCmd('ssh %s root@%s %s' % (sshargs, qemu.ip, testcommand))
- self.assertEqual(result.status, 0, 'File %s was not created at firts boot'%
fileboot_name)
+ ssh = SSHControl(ip=qemu.ip, logfile=qemu.sshlog)
+ status, output = ssh.run(testcommand)
+ self.assertEqual(status, 0, 'File %s was not created at first boot (%s)' %
(fileboot_name, output))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]