← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1470279] Re: ofagent unittest failes for multiple mock patches

 

** Project changed: neutron => networking-ofagent

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1470279

Title:
  ofagent unittest failes for multiple mock patches

Status in OpenStack Networking ofagent driver and its agent:
  In Progress

Bug description:
  gate-networking-ofagent-python27 job failes with the following error.
  This error is caused by using multiple patches to same target.
  That was forbidden by https://review.openstack.org/#/c/195881/.

  2015-06-30 06:35:00.771 | {0} networking_ofagent.tests.unit.ofagent.test_arp_lib.TestArpLib.test_packet_in_handler_corrupted [0.030123s] ... FAILED
  2015-06-30 06:35:00.772 | 
  2015-06-30 06:35:00.772 | Captured traceback:
  2015-06-30 06:35:00.772 | ~~~~~~~~~~~~~~~~~~~
  2015-06-30 06:35:00.772 |     Traceback (most recent call last):
  2015-06-30 06:35:00.772 |       File "networking_ofagent/tests/unit/ofagent/test_arp_lib.py", line 311, in test_packet_in_handler_corrupted
  2015-06-30 06:35:00.772 |         side_effect=ValueError).start()
  2015-06-30 06:35:00.772 |       File "/home/jenkins/workspace/gate-networking-ofagent-python27/.tox/py27/src/neutron/neutron/tests/base.py", line 191, in new_start
  2015-06-30 06:35:00.772 |         ''.join(self.first_traceback.get(key, []))))
  2015-06-30 06:35:00.772 |       File "/home/jenkins/workspace/gate-networking-ofagent-python27/.tox/py27/local/lib/python2.7/site-packages/unittest2/case.py", line 666, in fail
  2015-06-30 06:35:00.772 |         raise self.failureException(msg)
  2015-06-30 06:35:00.772 |     AssertionError: mock.patch was setup on an already patched target Mod(ryu.lib.packet.packet).Packet. Stop the original patch before starting a new one. Traceback of 1st patch:   File "/usr/lib/python2.7/runpy.py", line 162, in _run_module_as_main
  2015-06-30 06:35:00.773 |         "__main__", fname, loader, pkg_name)
  2015-06-30 06:35:00.773 |       File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
  2015-06-30 06:35:00.773 |         exec code in run_globals
  2015-06-30 06:35:00.773 |       File "/home/jenkins/workspace/gate-networking-ofagent-python27/.tox/py27/lib/python2.7/site-packages/subunit/run.py", line 149, in <module>
  2015-06-30 06:35:00.773 |         main()

  
  The wole log can be got from the following address.

  http://logs.openstack.org/00/184900/3/check/gate-networking-ofagent-
  python27/18ee891/console.html

To manage notifications about this bug go to:
https://bugs.launchpad.net/networking-ofagent/+bug/1470279/+subscriptions


References