summaryrefslogtreecommitdiffstats
path: root/tests/unit/test_service.py
Commit message (Collapse)AuthorAgeFilesLines
* Add graceful service shutdown support to LauncherBrian Elliott2013-06-301-0/+27
| | | | | | | | | Provides support for letting each running service finish in-progress requests and cleanup gracefully before stopping. blueprint graceful-shutdown Change-Id: Idf137620b87417de89eba23f05daf08780dc9dff
* Improve usability when backdoor_port is nonzeroRaymond Pekowski2013-06-231-4/+58
| | | | | | | | | | | | | | | Users who may not know that configuring a backdoor_port with 0 allows multiple services to be enabled for the eventlet backdoor or who simply want a more predictable port assignment might like this patch. If the specified port is in use, it is incremented until a free port is found. This is a backdoor_port collision recovery scheme as opposed to the collision failure scheme that exists today. This related to I95fdb5ca: Add support for backdoor_port to be returned with a rpc call. Change-Id: I7ec346db3575995fa15483b617eea34c1e003bb0
* Enable hacking H404 test.Dina Belova2013-06-111-3/+1
| | | | | | H404 - multi line docstring should start with a summary. Change-Id: I2099e1ee81ff9657f7a07401b8e8f3327d03bdbd
* Enable hacking H402 testSergey Lukjanov2013-06-031-1/+1
| | | | | | H402 one line docstring needs punctuation Change-Id: Ie848453cace318d8310cdf0234c512f4c1121119
* Pass backdoor_port to services being launchedBrian Elliott2013-05-091-0/+10
| | | | Change-Id: I7227648f9b9e1d3e30f4b2d03964ee5c625a1024
* Use print_function __future__ importMark McLoughlin2013-04-221-0/+3
| | | | | | | | | Rather than continuing to use the old print statement, use the actual print function introduced in python 2.6. See: http://docs.python.org/2/whatsnew/2.6.html#pep-3105-print-as-a-function Change-Id: I059d982d60e13f13e1caf49509c0fe0b18eda723
* Improve Python 3.x compatibilityDirk Mueller2013-04-221-1/+1
| | | | | | | Mechanical translation of deprecated constructs to 3.x compatible variants. Change-Id: I4988d0ac656903e0d0320aaa8361d4eeb774a0f9
* Removes unused imports in the tests moduleZhongyue Luo2013-03-201-2/+0
| | | | | | Fixes bug #1157596 Change-Id: I36d5484eaa2f0e21188eed6e70cc1ad785233d6a
* Use oslo-config-2013.1b3Mark McLoughlin2013-02-171-1/+1
| | | | | | | | | | | | | | | The cfg API is now available via the oslo-config library, so switch to it and remove the copied-and-pasted version. Add the 2013.1b3 tarball to tools/pip-requires - this will be changed to 'oslo-config>=2013.1' when oslo-config is published to pypi. This will happen in time for grizzly final. Remove the 'deps = pep8==1.3.3' and 'deps = pyflakes' from tox.ini as it means all the other deps get installed with easy_install which can't install oslo-config from the URL. Change-Id: I4815aeb8a9341a31a250e920157f15ee15cfc5bc
* Use testtools as test base class.Monty Taylor2013-01-241-5/+4
| | | | | | | | | | | | | On the path to testr migration, we need to replace the unittest base classes with testtools. Replace tearDown with addCleanup, addCleanup is more resilient than tearDown. The fixtures library has excellent support for managing and cleaning tempfiles. Use it. Replace skip_ with testtools.skipTest Part of blueprint grizzly-testtools. Change-Id: I45e11bbb1ff9b31f3278d3b016737dcb7850cd98
* Fix test cases in tests.unit.test_serviceHengqing Hu2013-01-031-28/+26
| | | | | | | | | | Be patient in test_service while waiting service to be spawned or killed, because: * Service spawning has a limit of one process a second. * A test server in the cloud might have limited resources, the time there might be several times slower. Change-Id: Idab1d1158ecc7564d0b1f9cdd32496496ff5b3f8
* Log CONF from ProcessLauncher.wait, like ServiceLauncherDavid Ripton2012-10-311-1/+11
| | | | | | | | | | Fixes bug #1050380 In the unit tests, we need to call CONF so that the config-file option referenced by log_opt_values() is registered. We also need unregister the default_publisher_id option to workaround bug #107372. Change-Id: Icc63237ddf97aaa730c0484974ec05a3080f8f04
* Add the rpc service and delete managerAngus Salkeld2012-09-261-3/+2
| | | | | | Part of blueprint service-infrastructure Change-Id: Ie00efcb1c974d699ac6b2a38285abef1b295f3ce
* Add threadgroup to manage timers and greenthreads.Angus Salkeld2012-08-201-1/+11
| | | | | | | Part of blueprint service-infrastructure Change-Id: I40593b6ad13d99d9e63c8c04154a0dac5aced02e Signed-off-by: Angus Salkeld <asalkeld@redhat.com>
* Add multiprocess service launcherAngus Salkeld2012-08-201-1/+136
| | | | | | | Part of blueprint service-infrastructure Signed-off-by: Angus Salkeld <asalkeld@redhat.com> Change-Id: I848e8c91d2c331e5c78a176258318457a9041131
* Basic service launching infrastructureAngus Salkeld2012-08-151-0/+40
Part of blueprint service-infrastructure Change-Id: I4e97db2877be976b0c681da9ff0d331fbfb306b0 Signed-off-by: Angus Salkeld <asalkeld@redhat.com>