Bug 1331981

Summary: tests: AttributeError: 'RepoStub' object has no attribute 'priority'
Product: [Fedora] Fedora Reporter: Igor Gnatenko <ignatenko>
Component: dnf-plugins-coreAssignee: Packaging Maintenance Team <packaging-team-maint>
Status: CLOSED UPSTREAM QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: jsilhan, mluscon, packaging-team-maint, pnemade, RadekHolyPublic, vmukhame
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-05-02 10:01:19 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Igor Gnatenko 2016-04-30 23:21:32 UTC
======================================================================
ERROR: test_enable_debuginfo_repos (tests.test_download.DownloadCommandTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/dnf-plugins-core-0.1.20_1-5g10a1d11/tests/test_download.py", line 282, in test_enable_debuginfo_repos
    dnfpluginscore.lib.enable_debug_repos(repos)
  File "/builddir/build/BUILD/dnf-plugins-core-0.1.20_1-5g10a1d11/plugins/dnfpluginscore/lib.py", line 146, in enable_debug_repos
    _enable_sub_repos(repos, debug_name)
  File "/builddir/build/BUILD/dnf-plugins-core-0.1.20_1-5g10a1d11/plugins/dnfpluginscore/lib.py", line 122, in _enable_sub_repos
    for repo in repos.iter_enabled():
  File "/usr/lib/python2.7/site-packages/dnf/repodict.py", line 62, in iter_enabled
    return (r for r in self.values() if r.enabled)
  File "/usr/lib/python2.7/site-packages/dnf/repodict.py", line 77, in values
    return (v for k, v in self.items())
  File "/usr/lib/python2.7/site-packages/dnf/repodict.py", line 68, in items
    key=lambda x: (x[1].priority, x[1].cost)))
  File "/usr/lib/python2.7/site-packages/dnf/repodict.py", line 68, in <lambda>
    key=lambda x: (x[1].priority, x[1].cost)))
AttributeError: 'RepoStub' object has no attribute 'priority'
======================================================================
ERROR: test_enable_source_repos (tests.test_download.DownloadCommandTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/dnf-plugins-core-0.1.20_1-5g10a1d11/tests/test_download.py", line 273, in test_enable_source_repos
    dnfpluginscore.lib.enable_source_repos(repos)
  File "/builddir/build/BUILD/dnf-plugins-core-0.1.20_1-5g10a1d11/plugins/dnfpluginscore/lib.py", line 136, in enable_source_repos
    _enable_sub_repos(repos, source_name)
  File "/builddir/build/BUILD/dnf-plugins-core-0.1.20_1-5g10a1d11/plugins/dnfpluginscore/lib.py", line 122, in _enable_sub_repos
    for repo in repos.iter_enabled():
  File "/usr/lib/python2.7/site-packages/dnf/repodict.py", line 62, in iter_enabled
    return (r for r in self.values() if r.enabled)
  File "/usr/lib/python2.7/site-packages/dnf/repodict.py", line 77, in values
    return (v for k, v in self.items())
  File "/usr/lib/python2.7/site-packages/dnf/repodict.py", line 68, in items
    key=lambda x: (x[1].priority, x[1].cost)))
  File "/usr/lib/python2.7/site-packages/dnf/repodict.py", line 68, in <lambda>
    key=lambda x: (x[1].priority, x[1].cost)))
AttributeError: 'RepoStub' object has no attribute 'priority'
----------------------------------------------------------------------