tacker/tacker
bhagyashris e855062154 Fix random failing of test_init_monitoring test
The existing unit test case [1] is failing randomly [2]
when both test modules `test_plugin` and `test_monitoring`
runs in a single worker.

Reason: VNFMonitor class is using singleton pattern.
In above test modules same object of VNFMonitor class
is returned from __new__ method but internally it makes
a call __init__ explicitly.
Since we are not initializing `_hosting_vnfs` attribute in
the __init__ method, when we try to access __hosting_vnf in
the second test `test_plugin`, it finds two vnf objects.

This issue is fixed in this patch by reinitializing the
`_hosting_vnfs` class level attribute as empty dict in the
test_init_monitoring unit test.

[1]: https://github.com/openstack/tacker/blob/master/tacker/tests/unit/vnfm/test_plugin.py#L75
[2]: http://logs.openstack.org/10/609610/9/check/openstack-tox-py35/b99de12/testr_results.html.gz

Change-Id: I2a5933ed21e478e860cb12b378a4368f9402291d
(cherry picked from commit 4b9bcfeeef)
2019-01-24 01:15:34 +00:00
..
agent Remove log translations 2017-07-07 00:19:36 -04:00
api Fix VIM register API 500 error issue 2018-08-01 14:07:46 +05:30
cmd Enable mutable config in tacker 2018-07-25 03:55:02 +05:30
common Fix eventlet issue 2018-07-17 17:36:23 +09:00
conductor Enable mutable config in tacker 2018-07-25 03:55:02 +05:30
db Add 'symmetrical' as property of a forwarding path 2018-08-06 11:09:03 +00:00
extensions Fix VIM register API 500 error issue 2018-08-01 14:07:46 +05:30
hacking rename various files of neutron/*.py to tacker/*.py 2014-07-04 18:20:50 +09:00
keymgr Support shared vim for policy action execution 2018-07-29 13:56:45 +08:00
locale Imported Translations from Zanata 2018-10-03 07:50:47 +00:00
mistral Replaces uuid.uuid4 with uuidutils.generate_uuid() 2017-07-18 14:00:58 +00:00
nfvo Support shared vim for policy action execution 2018-07-29 13:56:45 +08:00
plugins Implement vim status update in conductor 2017-06-20 11:47:16 +08:00
releasenotes/notes Remove infra and mgmt parsing logic from API 2017-01-06 08:39:56 +00:00
services Remove unused import logging 2016-05-12 10:52:23 +08:00
tests Fix random failing of test_init_monitoring test 2019-01-24 01:15:34 +00:00
tosca Add 'symmetrical' as property of a forwarding path 2018-08-06 11:09:03 +00:00
vnfm Fix random failing of test_init_monitoring test 2019-01-24 01:15:34 +00:00
__init__.py Cleanup vim settings 2016-03-28 13:03:56 +02:00
_i18n.py Remove log translations 2017-04-06 13:46:04 +08:00
alarm_receiver.py fix various typos in different messages 2018-02-10 22:01:04 +01:00
auth.py Remove log translations 2017-07-07 00:19:36 -04:00
context.py Support shared vim for policy action execution 2018-07-29 13:56:45 +08:00
manager.py Remove log translations 2017-07-07 00:19:36 -04:00
policy.py fix various typos in different messages 2018-02-10 22:01:04 +01:00
service.py introduce tacker conductor 2017-06-08 21:20:20 +08:00
version.py Cleanup vim settings 2016-03-28 13:03:56 +02:00
wsgi.py Enable mutable config in tacker 2018-07-25 03:55:02 +05:30