Minor cleanup based on HACKING

Change-Id: I59f02c33c3ecb0c446755a07562060a12f85e177
This commit is contained in:
Joe Gordon
2012-02-29 23:06:09 -08:00
parent a5c7f45a97
commit a04dc3e469
3 changed files with 6 additions and 6 deletions

View File

@@ -13,11 +13,11 @@
# License for the specific language governing permissions and limitations
# under the License.
import nova.exception
from nova import flags
from nova import log as logging
from nova.openstack.common import cfg
from nova import utils
from nova.exception import ClassNotFound
list_notifier_drivers_opt = cfg.MultiStrOpt('list_notifier_drivers',
@@ -50,7 +50,7 @@ def _get_drivers():
for notification_driver in FLAGS.list_notifier_drivers:
try:
drivers.append(utils.import_object(notification_driver))
except ClassNotFound as e:
except nova.exception.ClassNotFound as e:
drivers.append(ImportFailureNotifier(e))
return drivers

View File

@@ -24,7 +24,8 @@ from nova.scheduler import least_cost
from nova.scheduler import host_manager
from nova.scheduler import distributed_scheduler
from nova import test
from nova.tests.scheduler import fakes, test_scheduler
from nova.tests.scheduler import fakes
from nova.tests.scheduler import test_scheduler
def fake_filter_hosts(hosts, filter_properties):

View File

@@ -26,7 +26,6 @@ from eventlet import greenthread
from nova import exception
from nova import test
from nova import utils
from nova.utils import parse_mailmap, str_dict_replace
class ExceptionTestCase(test.TestCase):
@@ -46,7 +45,7 @@ class ProjectTestCase(test.TestCase):
topdir = os.path.normpath(os.path.dirname(__file__) + '/../../')
missing = set()
contributors = set()
mailmap = parse_mailmap(os.path.join(topdir, '.mailmap'))
mailmap = utils.parse_mailmap(os.path.join(topdir, '.mailmap'))
authors_file = open(os.path.join(topdir,
'Authors'), 'r').read().lower()
@@ -57,7 +56,7 @@ class ProjectTestCase(test.TestCase):
if "jenkins" in email and "openstack.org" in email:
continue
email = '<' + email.lower() + '>'
contributors.add(str_dict_replace(email, mailmap))
contributors.add(utils.str_dict_replace(email, mailmap))
else:
return