← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1381414] [NEW] Unit test failure "AssertionError: Expected to be called once. Called 2 times." in test_get_port_vnic_info_3

 

Public bug reported:

This looks to be due to tests test_get_port_vnic_info_2 and 3 sharing
some code and is easily reproduced by running these two tests alone with
no concurrency.

./run_tests.sh --concurrency 1 test_get_port_vnic_info_2
test_get_port_vnic_info_3

The above always results in:

Traceback (most recent call last):
  File "/home/hans/nova/nova/tests/network/test_neutronv2.py", line 2615, in test_get_port_vnic_info_3
    self._test_get_port_vnic_info()
  File "/home/hans/nova/.venv/local/lib/python2.7/site-packages/mock.py", line 1201, in patched
    return func(*args, **keywargs)
  File "/home/hans/nova/nova/tests/network/test_neutronv2.py", line 2607, in _test_get_port_vnic_info
    fields=['binding:vnic_type', 'network_id'])
  File "/home/hans/nova/.venv/local/lib/python2.7/site-packages/mock.py", line 845, in assert_called_once_with
    raise AssertionError(msg)
AssertionError: Expected to be called once. Called 2 times.

** Affects: nova
     Importance: Undecided
     Assignee: Hans Lindgren (hanlind)
         Status: New


** Tags: testing

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1381414

Title:
  Unit test failure "AssertionError: Expected to be called once. Called
  2 times." in test_get_port_vnic_info_3

Status in OpenStack Compute (Nova):
  New

Bug description:
  This looks to be due to tests test_get_port_vnic_info_2 and 3 sharing
  some code and is easily reproduced by running these two tests alone
  with no concurrency.

  ./run_tests.sh --concurrency 1 test_get_port_vnic_info_2
  test_get_port_vnic_info_3

  The above always results in:

  Traceback (most recent call last):
    File "/home/hans/nova/nova/tests/network/test_neutronv2.py", line 2615, in test_get_port_vnic_info_3
      self._test_get_port_vnic_info()
    File "/home/hans/nova/.venv/local/lib/python2.7/site-packages/mock.py", line 1201, in patched
      return func(*args, **keywargs)
    File "/home/hans/nova/nova/tests/network/test_neutronv2.py", line 2607, in _test_get_port_vnic_info
      fields=['binding:vnic_type', 'network_id'])
    File "/home/hans/nova/.venv/local/lib/python2.7/site-packages/mock.py", line 845, in assert_called_once_with
      raise AssertionError(msg)
  AssertionError: Expected to be called once. Called 2 times.

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1381414/+subscriptions


Follow ups

References