linux IP lib tests conflicting patches causing sporadic UT failures
Bug #1307038 reported by
Kevin Benton
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
neutron |
Fix Released
|
Undecided
|
Kevin Benton |
Bug Description
The following failure is happening sporadically when running the unit tests:
ft1.11275: neutron.
pythonlogging:''
pythonlogging
stderr
stdout
Traceback (most recent call last):
File "neutron/
_execute.
File "/home/
raise AssertionError(msg)
AssertionError: Expected to be called once. Called 0 times.
Changed in neutron: | |
assignee: | nobody → Kevin Benton (kevinbenton) |
Changed in neutron: | |
status: | New → In Progress |
Changed in neutron: | |
milestone: | none → juno-1 |
status: | Fix Committed → Fix Released |
Changed in neutron: | |
milestone: | juno-1 → 2014.2 |
To post a comment you must log in.
The root cause of this is the TestMidonetInte rfaceDriver test class. The class it inherits from already patches the 'device_exists' method in ip_lib during setup and then it does it again[1]. Double-patching causes the mock library to fail to stop both patches using the stopall method.
This bug surface after the patch merged that removed all of the explicit addCleanup( patch.stop) methods from unit tests.[2]
1. https:/ /github. com/bigswitch/ neutron/ blob/1e0ea5217a 93fadb915c3dcdf 4c260738bed70ac /neutron/ tests/unit/ test_linux_ interface. py#L518
2. https:/ /review. openstack. org/#/c/ 86538/