unit tests fail under code coverage
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
neutron |
Fix Released
|
Medium
|
Mark McClain |
Bug Description
12 unit tests fail when run with code coverage enabled. All of them located in 'test_debug_
ERROR: test_ping_
-------
Traceback (most recent call last):
File "/home/
self.
File "/home/
test(result)
File "/home/
return self.run(*args, **kwds)
File "/home/
self.setUp()
File "/home/
cfg.
File "/home/
self.
File "/home/
values, leftovers = self._oparser.
File "/usr/lib/
self.
File "/usr/lib/
self.exit(2, "%s: error: %s\n" % (self.get_
File "/usr/lib/
sys.
SystemExit: 2
The issue is in the line 44 of test_debug_
cfg.CONF(
When run with coverage there's an additional cli parameter '--with-coverage' that causes optparse to fall with error.
The possible fix is to add parameter specification:
@@ -40,6 +41,7 @@ class TestDebugComman
def setUp(self):
+ cfg.CONF.
Changed in quantum: | |
status: | New → Confirmed |
importance: | Undecided → Medium |
assignee: | nobody → Mark McClain (markmcclain) |
Changed in quantum: | |
milestone: | none → grizzly-2 |
status: | Fix Committed → Fix Released |
Changed in quantum: | |
milestone: | grizzly-2 → 2013.1 |
Fix proposed to branch: master /review. openstack. org/16662
Review: https:/