Bug 488145 - FEAT: HTS should provide a run-time dependency option for installation
Summary: FEAT: HTS should provide a run-time dependency option for installation
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Hardware Certification Program
Classification: Retired
Component: Test Suite (harness)
Version: 5.3
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
: ---
Assignee: Greg Nichols
QA Contact: Lawrence Lim
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-03-02 21:14 UTC by Greg Nichols
Modified: 2014-03-26 00:56 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-04-21 15:57:46 UTC
Embargoed:


Attachments (Terms of Use)
hardwaretest.py patch adding test-specified package installation (2.76 KB, application/octet-stream)
2010-01-11 11:52 UTC, Greg Nichols
no flags Details
test.py patch defining a default getRequiredRPMs that returns an empy list. (409 bytes, patch)
2010-01-11 11:53 UTC, Greg Nichols
no flags Details | Diff
fvtest.py patch with getRequiredRPMs implementation (14.84 KB, patch)
2010-01-11 11:57 UTC, Greg Nichols
no flags Details | Diff
hardwaretest.py patch on R22 adding --mode auto support (713 bytes, patch)
2010-01-13 00:53 UTC, Greg Nichols
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2010:0365 0 normal SHIPPED_LIVE v7 bug fix and enhancement update 2010-04-21 15:56:59 UTC

Description Greg Nichols 2009-03-02 21:14:32 UTC
Description of problem:

The HTS package currently defines a full set of required packages for the whole test suite.   This approach means that it requires packages that are not allways needed to test a particular system.  For example, mt is required by the tape test, and the HTS package requires the mt package even if there's no tape drive in the system under test.

HTS should provide an alternative package with minimal required packages, and validate any required packages at run time according to scheduled tests.  This minimal rpm could be a separate package from the "full requires" version.

Comment 2 Greg Nichols 2010-01-11 11:52:48 UTC
Created attachment 382964 [details]
hardwaretest.py patch adding test-specified package installation

This patch adds test-specified package installation to the planning phase of the harness.   When a new test plan is created, the list of tests are checked for additional required packages.  If any are found that are not installed, the harness asks the user if they would like to isntall them.

If the user agrees, the hardness calls yum with the package list, then re-checks the required packages.   If the user does not agree, the harness prints a warning message.

Test-required packages are only checked when a new plan is created, not when the plan is changed via hardware detection, or user edits.

Comment 3 Greg Nichols 2010-01-11 11:53:59 UTC
Created attachment 382965 [details]
test.py patch defining a default getRequiredRPMs that returns an empy list.

Comment 4 Greg Nichols 2010-01-11 11:57:48 UTC
Created attachment 382966 [details]
fvtest.py patch with getRequiredRPMs implementation

+    def getRequiredRPMs(self):
+        rpms = ["qemu", "libvirt", "libvirt-python", "python-virtinst"]
+        return rpms
+    

Note that other tests may implement this function to do specific tests on hardware or RHEL configuration.

Comment 5 Greg Nichols 2010-01-11 15:43:49 UTC
Actually, there's no need to the qemu package under xen, so the function should be:

def getRequiredRPMs(self):
        rpms = ["libvirt", "libvirt-python", "python-virtinst"]
        if self.hypervisor == Constants.kvm:
            rpms.append('qemu')
        return rpms

Comment 6 Greg Nichols 2010-01-12 16:29:26 UTC
committed patches.

Comment 7 Greg Nichols 2010-01-13 00:53:18 UTC
Created attachment 383385 [details]
hardwaretest.py patch on R22 adding --mode auto support

In --mode auto, the required rpms are added automatically.

Comment 10 errata-xmlrpc 2010-04-21 15:57:46 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2010-0365.html


Note You need to log in before you can comment on or make changes to this bug.