]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
tests/unit: Initialize core plugin in TestL3GwModeMixin
authorIsaku Yamahata <isaku.yamahata@intel.com>
Tue, 18 Feb 2014 02:02:56 +0000 (11:02 +0900)
committerThomas Goirand <thomas@goirand.fr>
Thu, 13 Mar 2014 07:20:25 +0000 (15:20 +0800)
commit50ea016953f74144aec24ba6fd48b0d3215ff1a2
tree4ee7df96aa21a0fd05e223829066064011c5fadf
parentfcfa47ca540d7dcf1d9084f2a546ff355a306723
tests/unit: Initialize core plugin in TestL3GwModeMixin

TestL3GwModeMixin can fail randomly because it doesn't initialize
core_plugin and can be run random core plugin depending on execution
order of tests. It also fails with core plugin uninitialized when it
is run without other tests.

This patch refactors the setup code of core plugin and apply it to the
related tests.
This patch reveled the same bug of test_metaplugin.py which is also
fixed by this patch.

Closes-bug: #1273259
Change-Id: I3c1d4d8b3d69262b89c7747daa8267bf2c8e7f6b
15 files changed:
neutron/tests/base.py
neutron/tests/unit/metaplugin/test_metaplugin.py
neutron/tests/unit/nicira/test_networkgw.py
neutron/tests/unit/services/loadbalancer/test_loadbalancer_plugin.py
neutron/tests/unit/services/vpn/test_vpnaas_extension.py
neutron/tests/unit/test_api_v2.py
neutron/tests/unit/test_db_plugin.py
neutron/tests/unit/test_extension_ext_gw_mode.py
neutron/tests/unit/test_extension_extended_attribute.py
neutron/tests/unit/test_extension_firewall.py
neutron/tests/unit/test_extension_pnet.py
neutron/tests/unit/test_neutron_manager.py
neutron/tests/unit/test_quota_ext.py
neutron/tests/unit/test_routerserviceinsertion.py
neutron/tests/unit/test_servicetype.py