Bug 1223475 - all ice-setup tests are failing
Summary: all ice-setup tests are failing
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Ceph Storage
Classification: Red Hat Storage
Component: Ceph-Installer
Version: 1.3.0
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: rc
: 1.3.0
Assignee: Alfredo Deza
QA Contact: ceph-qe-bugs
URL:
Whiteboard:
Depends On:
Blocks: 1219294
TreeView+ depends on / blocked
 
Reported: 2015-05-20 15:20 UTC by Alfredo Deza
Modified: 2017-12-13 00:25 UTC (History)
7 users (show)

Fixed In Version: ice_setup-0.4.1-1.el7cp
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-06-24 15:53:12 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:1183 0 normal SHIPPED_LIVE Ceph bug fix and enhancement update 2015-06-24 19:49:46 UTC

Description Alfredo Deza 2015-05-20 15:20:59 UTC
Description of problem: All ice setup tests are failing, preventing a release


Version-Release number of selected component (if applicable):


How reproducible: Always


Steps to Reproduce:
1. run py.test on the repository

Actual results:
============================= test session starts ==============================
platform linux2 -- Python 2.7.5 -- pytest-2.3.5
collected 43 items / 1 errors
ice_setup/tests/test_distributions.py FFFFFFFFFFFF
ice_setup/tests/test_paths.py ..FF
ice_setup/tests/test_prompts.py ...........................
==================================== ERRORS ====================================
_______________ ERROR collecting ice_setup/tests/test_system.py ________________
ice_setup/tests/test_system.py:6: in <module>
>   from ice_setup.ice import get_fqdn, infer_ceph_repo, ICEError, DirNotFound
E   ImportError: cannot import name infer_ceph_repo
=================================== FAILURES ===================================
______________________ TestYum.test_creates_default_file _______________________
self = <ice_setup.tests.test_distributions.TestYum object at 0x2550210>
etc_path = '/tmp/tmpeCMO62'
    def test_creates_default_file(self, etc_path):
>       Yum.create_repo_file('ceph', 'repo_url', 'gpg_url', etc_path=etc_path)
ice_setup/tests/test_distributions.py:20:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
cls = <class 'ice_setup.ice.Yum'>, template_name = 'ceph', repo_url = 'repo_url'
gpg_url = 'gpg_url', file_name = 'ice.repo', use_gpg = True, kw = {}
etc_path = '/tmp/tmpeCMO62'
    @classmethod
    def create_repo_file(cls, template_name, repo_url, gpg_url, file_name=None, use_gpg=True, **kw):
        """set the contents of /etc/yum.repos.d/ice.repo"""
        etc_path = kw.pop('etc_path', '/etc/yum.repos.d')
        file_name = '%s.repo' % (file_name or 'ice')
>       template = yum_templates[template_name]
E       KeyError: 'ceph'
ice_setup/ice.py:583: KeyError

Expected results:
All tests passed

Comment 2 Ken Dreyer (Red Hat) 2015-05-20 16:02:57 UTC
Fixed upstream in https://github.com/ceph/ice-setup/pull/36

Comment 5 Harish NV Rao 2015-05-21 04:45:24 UTC
This bug seems to be caught during unit tests. QE will run installation tests referring to installation doc which will include ice_setup. QE will not run unit tests. ACKing this bug as this bug can be verified implicitly via installation tests.

Comment 8 Ken Dreyer (Red Hat) 2015-06-01 20:18:18 UTC
I'm going to mark this as VERIFIED myself because I've confirmed that the unit tests now pass.


============================= test session starts ==============================
platform linux2 -- Python 2.7.5 -- pytest-2.3.5
collected 43 items
ice_setup/tests/test_distributions.py ..........
ice_setup/tests/test_paths.py ...
ice_setup/tests/test_prompts.py ...........................
ice_setup/tests/test_system.py ...
========================== 43 passed in 0.14 seconds ===========================

Comment 10 errata-xmlrpc 2015-06-24 15:53:12 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2015:1183


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