Add eventlet test check to new tests __init__.py

This is used to allow us to test both with and without eventlet.
It wasn't copied to the new tests directory in the namespace move,
which means that once the old tests go away eventlet won't be
monkey patching even when we try to make it.  Also, there's a race
depending on whether the top-level tests are run first, or the new
package ones.

Change-Id: Ie2705c3d21625e594471f27eefc3ac3147390cb7
This commit is contained in:
Ben Nemec 2015-02-06 17:32:39 +00:00
parent 67181a8610
commit 2a9321e65a

View File

@ -0,0 +1,19 @@
# Copyright 2014 Red Hat, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import os
if os.environ.get('TEST_EVENTLET'):
import eventlet
eventlet.monkey_patch()