Cleanup tests imports so not relative

This change cleans up the imports in tests packages by changing
relative local imports to absolute imports per OpenStack hacking
guidelines.

Change-Id: I63c493b6a263e896f92479996c4fa4f783adff9a
This commit is contained in:
Brant Knudson 2013-09-08 14:33:54 -05:00 committed by Gerrit Code Review
parent 33c8025094
commit 77092b406b
38 changed files with 53 additions and 89 deletions

View File

@ -24,8 +24,7 @@ from keystone import config
from keystone import exception
from keystone.identity.backends import ldap as identity_ldap
from keystone import tests
import test_backend_ldap
from keystone.tests import test_backend_ldap
CONF = config.CONF

View File

@ -22,8 +22,7 @@ from keystone import config
from keystone import exception
from keystone import identity
from keystone import tests
import _ldap_livetest
from keystone.tests import _ldap_livetest
CONF = config.CONF

View File

@ -14,9 +14,9 @@
# License for the specific language governing permissions and limitations
# under the License.
import test_sql_upgrade
from keystone import config
from keystone.tests import test_sql_upgrade
CONF = config.CONF

View File

@ -21,8 +21,7 @@ from keystone.common.sql import migration
from keystone import contrib
from keystone.openstack.common import importutils
from keystone import tests
import test_v3
from keystone.tests import test_v3
class TestExtensionCase(test_v3.RestfulTestCase):

View File

@ -16,17 +16,15 @@ import copy
import datetime
import uuid
from keystone import tests
from keystone import auth
from keystone import config
from keystone import exception
from keystone.openstack.common import timeutils
from keystone import tests
from keystone.tests import default_fixtures
from keystone import token
from keystone import trust
import default_fixtures
CONF = config.CONF
TIME_FORMAT = '%Y-%m-%dT%H:%M:%S.%fZ'

View File

@ -16,10 +16,9 @@
import uuid
from keystone import tests
from keystone import auth
from keystone import exception
from keystone import tests
from keystone import token

View File

@ -18,14 +18,12 @@ import copy
import datetime
import uuid
from keystone import tests
from keystone.catalog import core
from keystone import config
from keystone import exception
from keystone.openstack.common import timeutils
import default_fixtures
from keystone import tests
from keystone.tests import default_fixtures
CONF = config.CONF

View File

@ -18,9 +18,8 @@ import uuid
from keystone import exception
from keystone import identity
from keystone import tests
import default_fixtures
import test_backend
from keystone.tests import default_fixtures
from keystone.tests import test_backend
class KvsIdentity(tests.TestCase, test_backend.IdentityTests):

View File

@ -28,9 +28,8 @@ from keystone import config
from keystone import exception
from keystone import identity
from keystone import tests
import default_fixtures
import test_backend
from keystone.tests import default_fixtures
from keystone.tests import test_backend
CONF = config.CONF

View File

@ -20,18 +20,16 @@ import uuid
import memcache
from keystone import tests
from keystone.common import utils
from keystone import exception
from keystone.openstack.common import jsonutils
from keystone.openstack.common import timeutils
from keystone import tests
from keystone.tests import test_backend
from keystone.tests import test_utils
from keystone import token
from keystone.token.backends import memcache as token_memcache
import test_backend
import test_utils
class MemcacheClient(object):
"""Replicates a tiny subset of memcached client interface."""

View File

@ -16,10 +16,9 @@
import uuid
from keystone import tests
from keystone import config
from keystone.identity.backends import pam as identity_pam
from keystone import tests
CONF = config.CONF

View File

@ -22,9 +22,8 @@ from keystone.common import sql
from keystone import config
from keystone import exception
from keystone import tests
import default_fixtures
import test_backend
from keystone.tests import default_fixtures
from keystone.tests import test_backend
CONF = config.CONF

View File

@ -16,12 +16,11 @@
import os
from keystone import tests
from keystone import exception
from keystone import tests
from keystone.tests import default_fixtures
from keystone.tests import test_backend
import default_fixtures
import test_backend
DEFAULT_CATALOG_TEMPLATES = os.path.abspath(os.path.join(
os.path.dirname(__file__),

View File

@ -16,7 +16,7 @@
import uuid
import test_content_types
from keystone.tests import test_content_types
BASE_URL = 'http://127.0.0.1:35357/v2'

View File

@ -18,14 +18,12 @@
import os
import shutil
from keystone import tests
from keystone.common import openssl
from keystone import exception
from keystone import tests
from keystone.tests import default_fixtures
from keystone import token
import default_fixtures
ROOTDIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
SSLDIR = "%s/tests/ssl/" % ROOTDIR

View File

@ -14,10 +14,9 @@
# License for the specific language governing permissions and limitations
# under the License.
from keystone import tests
from keystone import config
from keystone import exception
from keystone import tests
CONF = config.CONF

View File

@ -20,13 +20,11 @@ import uuid
from lxml import etree
import webtest
from keystone import tests
from keystone.common import extension
from keystone.common import serializer
from keystone.openstack.common import jsonutils
import default_fixtures
from keystone import tests
from keystone.tests import default_fixtures
class RestfulTestCase(tests.TestCase):

View File

@ -16,11 +16,9 @@
import uuid
from keystone import tests
from keystone.contrib import s3
from keystone import exception
from keystone import tests
class S3ContribCore(tests.TestCase):

View File

@ -16,12 +16,11 @@
import uuid
from keystone import tests
from keystone.common import wsgi
from keystone import config
from keystone import exception
from keystone.openstack.common import jsonutils
from keystone import tests
CONF = config.CONF

View File

@ -15,10 +15,9 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from keystone import tests
from keystone.common import environment
from keystone import config
from keystone import tests
CONF = config.CONF

View File

@ -21,8 +21,8 @@ from keystone import config
from keystone.openstack.common import jsonutils
from keystone.openstack.common import timeutils
from keystone import tests
from keystone.tests import default_fixtures
import default_fixtures
CONF = config.CONF
DEFAULT_DOMAIN_ID = CONF.identity.default_domain_id

View File

@ -21,8 +21,7 @@ from keystoneclient.contrib.ec2 import utils as ec2_utils
from keystone.common import sql
from keystone import config
from keystone import tests
import test_keystoneclient
from keystone.tests import test_keystoneclient
CONF = config.CONF

View File

@ -16,11 +16,10 @@
import webob
from keystone import tests
from keystone import config
from keystone import middleware
from keystone.openstack.common import jsonutils
from keystone import tests
CONF = config.CONF

View File

@ -19,12 +19,11 @@ import StringIO
import tempfile
import urllib2
from keystone import tests
from keystone import config
from keystone import exception
from keystone.openstack.common import policy as common_policy
from keystone.policy.backends import rules
from keystone import tests
CONF = config.CONF

View File

@ -14,11 +14,11 @@
import webob
from keystone import tests
from keystone import config
from keystone import exception
from keystone import middleware
from keystone import tests
CONF = config.CONF
MAX_REQUEST_BODY_SIZE = CONF.max_request_body_size

View File

@ -30,8 +30,7 @@ To run these tests against a live database:
from keystone.contrib import endpoint_filter
from keystone.contrib import example
from keystone.contrib import oauth1
import test_sql_upgrade
from keystone.tests import test_sql_upgrade
class SqlUpgradeExampleExtension(test_sql_upgrade.SqlMigrateBase):

View File

@ -32,16 +32,14 @@ import uuid
from migrate.versioning import api as versioning_api
import sqlalchemy
from keystone import tests
from keystone.common import sql
from keystone.common.sql import migration
from keystone.common import utils
from keystone import config
from keystone import credential
from keystone import exception
import default_fixtures
from keystone import tests
from keystone.tests import default_fixtures
CONF = config.CONF

View File

@ -18,10 +18,10 @@
import os
import ssl
from keystone import tests
from keystone.common import environment
from keystone import config
from keystone import tests
CONF = config.CONF

View File

@ -16,9 +16,8 @@
import webob
from keystone import tests
from keystone import middleware
from keystone import tests
class FakeApp(object):

View File

@ -34,9 +34,9 @@ import functools
import os
import time
from keystone.common import utils
from keystone import tests
from keystone.common import utils
TZ = None

View File

@ -27,8 +27,7 @@ from keystone import config
from keystone.openstack.common import timeutils
from keystone.policy.backends import rules
from keystone import tests
import test_content_types
from keystone.tests import test_content_types
CONF = config.CONF

View File

@ -20,8 +20,7 @@ from keystone.common import cms
from keystone import config
from keystone import exception
from keystone import tests
import test_v3
from keystone.tests import test_v3
CONF = config.CONF

View File

@ -14,7 +14,7 @@
# License for the specific language governing permissions and limitations
# under the License.
import test_v3
from keystone.tests import test_v3
class CatalogTestCase(test_v3.RestfulTestCase):

View File

@ -18,7 +18,7 @@ import hashlib
import json
import uuid
import test_v3
from keystone.tests import test_v3
class CredentialTestCase(test_v3.RestfulTestCase):

View File

@ -17,8 +17,7 @@
import uuid
from keystone import exception
import test_v3
from keystone.tests import test_v3
def _build_role_assignment_url_and_entity(

View File

@ -26,8 +26,7 @@ from keystone import contrib
from keystone.contrib import oauth1
from keystone.contrib.oauth1 import controllers
from keystone.openstack.common import importutils
import test_v3
from keystone.tests import test_v3
CONF = config.CONF

View File

@ -16,7 +16,7 @@
import uuid
import test_v3
from keystone.tests import test_v3
class PolicyTestCase(test_v3.RestfulTestCase):

View File

@ -23,8 +23,7 @@ from keystone import exception
from keystone.openstack.common import jsonutils
from keystone.policy.backends import rules
from keystone import tests
import test_v3
from keystone.tests import test_v3
CONF = config.CONF