When trying to run the test_l3_agent unit tests individually the following test case fails:
======================================================================
ERROR: neutron.tests.unit.test_l3_agent.TestL3AgentEventHandler.test_spawn_metadata_proxy
----------------------------------------------------------------------
_StringException: Empty attachments:
pythonlogging:''
pythonlogging:'neutron.api.extensions'
Traceback (most recent call last):
File "/home/henry/Dev/neutron/neutron/tests/unit/test_l3_agent.py", line 1203, in setUp
'interface_driver', 'neutron.agent.linux.interface.NullDriver'
File "/usr/local/lib/python2.7/dist-packages/oslo/config/cfg.py", line 1547, in __inner
result = f(self, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/oslo/config/cfg.py", line 1797, in set_override
opt_info = self._get_opt_info(name, group)
File "/usr/local/lib/python2.7/dist-packages/oslo/config/cfg.py", line 2106, in _get_opt_info
raise NoSuchOptError(opt_name, group)
NoSuchOptError: no such option: interface_driver
Reviewed: https:/ /review. openstack. org/90808 /git.openstack. org/cgit/ openstack/ neutron/ commit/ ?id=2a51109aecd fd10b153badbc05 14948db10585c8
Committed: https:/
Submitter: Jenkins
Branch: master
commit 2a51109aecdfd10 b153badbc051494 8db10585c8
Author: Henry Gessau <email address hidden>
Date: Mon Apr 28 13:41:18 2014 -0400
Allow test_l3_agent unit test to run individually
When the test_l3_ agent.TestL3Age ntEventHandler test case is run
after test discovery it passes because discovery imports files
that registers all the config options. For the test case to run
individually we need to explicitly register the config options
used in the test.
Change-Id: Ic31503ad7be860 1ff843dbdc8edf5 856ce8b0e39
Closes-bug: #1313812