Trivial fix typos

Change-Id: Ib6ea796f2163ead6bf13865399c4a2aa89e75a2f
This commit is contained in:
Vu Cong Tuan 2017-05-16 10:47:19 +07:00
parent 956fd42eed
commit b5f5935c27
8 changed files with 19 additions and 19 deletions

View File

@ -88,7 +88,7 @@ REST_API_VERSION_HISTORY = """
# The minimum and maximum versions of the API supported
# The default api version request is defined to be the
# minimum version of the API supported.
# Explicitly using /v1 or /v2 enpoints will still work
# Explicitly using /v1 or /v2 endpoints will still work
_MIN_API_VERSION = "3.0"
_MAX_API_VERSION = "3.31"
_LEGACY_API_VERSION1 = "1.0"

View File

@ -153,7 +153,7 @@ class BackupMetadataAPI(base.Base):
:param metadata: master set of metadata
:param fields: list of fields we want to extract
:param excludes: fields to be exluded
:param excludes: fields to be excluded
:returns: filtered metadata
"""
if not fields:

View File

@ -19,9 +19,9 @@ from sqlalchemy import MetaData, Table
def upgrade(migrate_engine):
"""Add microseconds precission on updated_at field in MySQL databases.
"""Add microseconds precision on updated_at field in MySQL databases.
PostgreSQL, SQLite, and MSSQL have sub-second precission by default, but
PostgreSQL, SQLite, and MSSQL have sub-second precision by default, but
MySQL defaults to second precision in DateTime fields, which creates
problems for the resource cleanup mechanism.
"""

View File

@ -342,7 +342,7 @@ class GroupSnapshotsTest(functional_helpers._FunctionalTestBase):
found_volume = self._poll_volume_while(created_volume_id, ['deleting'])
found_group = self._poll_group_while(group_id, ['deleting'])
# Created resoueces should be gone
# Created resources should be gone
self.assertFalse(found_group_snapshot)
self.assertFalse(found_volume)
self.assertFalse(found_group)

View File

@ -49,13 +49,13 @@ class AttachmentsAPITestCase(test.TestCase):
project_id=fake.PROJECT_ID)
self.volume2 = self._create_volume(display_name='fake_volume_2',
project_id=fake.PROJECT2_ID)
self.attachment1 = self._create_attachement(
self.attachment1 = self._create_attachment(
volume_uuid=self.volume1.id, instance_uuid=fake.UUID1)
self.attachment2 = self._create_attachement(
self.attachment2 = self._create_attachment(
volume_uuid=self.volume1.id, instance_uuid=fake.UUID1)
self.attachment3 = self._create_attachement(
self.attachment3 = self._create_attachment(
volume_uuid=self.volume1.id, instance_uuid=fake.UUID2)
self.attachment4 = self._create_attachement(
self.attachment4 = self._create_attachment(
volume_uuid=self.volume2.id, instance_uuid=fake.UUID2)
self.addCleanup(self._cleanup)
@ -157,7 +157,7 @@ class AttachmentsAPITestCase(test.TestCase):
def test_delete_attachment(self, status, mock_delete):
volume1 = self._create_volume(display_name='fake_volume_1',
project_id=fake.PROJECT_ID)
attachment = self._create_attachement(
attachment = self._create_attachment(
volume_uuid=volume1.id, instance_uuid=fake.UUID1,
attach_status=status)
req = fakes.HTTPRequest.blank('/v3/%s/attachments/%s' %
@ -178,11 +178,11 @@ class AttachmentsAPITestCase(test.TestCase):
mock_delete.assert_called_once_with(req.environ['cinder.context'],
attachment.id, mock.ANY)
def _create_attachement(self, ctxt=None, volume_uuid=None,
instance_uuid=None, mountpoint=None,
attach_time=None, detach_time=None,
attach_status=None, attach_mode=None):
"""Create a attachement object."""
def _create_attachment(self, ctxt=None, volume_uuid=None,
instance_uuid=None, mountpoint=None,
attach_time=None, detach_time=None,
attach_status=None, attach_mode=None):
"""Create an attachment object."""
ctxt = ctxt or self.ctxt
attachment = objects.VolumeAttachment(ctxt)
attachment.volume_id = volume_uuid

View File

@ -557,7 +557,7 @@ class GoogleBackupDriverTestCase(test.TestCase):
self.assertGreater(len(fake_data), len(result))
@gcs_client
def test_prepare_output_data_no_compresssion(self):
def test_prepare_output_data_no_compression(self):
self.flags(backup_compression_algorithm='none')
service = google_dr.GoogleBackupDriver(self.ctxt)
# Set up buffer of 128 zeroed bytes

View File

@ -142,7 +142,7 @@ class FakeMethod(object):
""""Mock function to delete snapshot."""
def restoreFromSnapshot(self, *args, **kwargs):
""""Mock function to create a volume from a snasphot."""
""""Mock function to create a volume from a snapshot."""
def restoreDetail(self, *args, **kwargs):
""""Mock function to detail the restore operation."""

View File

@ -113,7 +113,7 @@ class VolumeCapabilitiesTestCase(base.BaseVolumeTestCase):
mock_init_vendor,
mock_get_volume_stats):
# Error test case: propety does not match vendor prefix
# Error test case: property does not match vendor prefix
def init_vendor_properties(self):
properties = {}
self._set_property(
@ -153,7 +153,7 @@ class VolumeCapabilitiesTestCase(base.BaseVolumeTestCase):
mock_init_vendor,
mock_get_volume_stats):
# Error test case: propety cannot override any standard capabilities
# Error test case: property cannot override any standard capabilities
def init_vendor_properties(self):
properties = {}
self._set_property(