Remove unicode
No longer necessary as we no longer support Python 2.7. Change-Id: Icae82ed323d25d85a35e12b8b4c980f0f71d5d85
This commit is contained in:
parent
6ca038f350
commit
6fee42ecac
@ -59,8 +59,8 @@ source_suffix = '.rst'
|
||||
master_doc = 'index'
|
||||
|
||||
# General information about the project.
|
||||
project = u'Designate API Reference'
|
||||
copyright = u'OpenStack Foundation'
|
||||
project = 'Designate API Reference'
|
||||
copyright = 'OpenStack Foundation'
|
||||
|
||||
# openstackdocstheme options
|
||||
openstackdocs_repo_name = 'openstack/designate'
|
||||
@ -100,7 +100,7 @@ pygments_style = 'native'
|
||||
# -- Options for man page output ----------------------------------------------
|
||||
|
||||
# Grouping the document tree for man pages.
|
||||
# List of tuples 'sourcefile', 'target', u'title', u'Authors name', 'manual'
|
||||
# List of tuples 'sourcefile', 'target', 'title', 'Authors name', 'manual'
|
||||
|
||||
|
||||
# -- Options for HTML output --------------------------------------------------
|
||||
@ -186,8 +186,8 @@ htmlhelp_basename = 'designatedoc'
|
||||
# (source start file, target name, title, author, documentclass
|
||||
# [howto/manual]).
|
||||
latex_documents = [
|
||||
('index', 'Designate.tex', u'OpenStack DNS API Documentation',
|
||||
u'OpenStack Foundation', 'manual'),
|
||||
('index', 'Designate.tex', 'OpenStack DNS API Documentation',
|
||||
'OpenStack Foundation', 'manual'),
|
||||
]
|
||||
|
||||
# The name of an image file (relative to this directory) to place at the top of
|
||||
|
@ -28,7 +28,7 @@ ALLOCATIONS = {}
|
||||
|
||||
def _format_floatingip(id_, address):
|
||||
return {
|
||||
'region': u'RegionOne',
|
||||
'region': 'RegionOne',
|
||||
'address': address,
|
||||
'id': id_
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Example input:
|
||||
# {u'mail.example.com.': {u'A': [u'192.0.2.1', u'192.0.2.2']}, u'www.example.com.': {u'A': [u'192.0.2.1', u'192.0.2.2']}}
|
||||
# {'mail.example.com.': {'A': ['192.0.2.1', '192.0.2.2']}, 'www.example.com.': {'A': ['192.0.2.1', '192.0.2.2']}}
|
||||
{% for name in template_data -%}
|
||||
{% for rdtype in template_data[name] -%}
|
||||
# RecordSet: {{name}} / {{rdtype}}
|
||||
|
@ -221,7 +221,7 @@ class TestCase(base.BaseTestCase):
|
||||
|
||||
blacklist_fixtures = [{
|
||||
'pattern': 'blacklisted.com.',
|
||||
'description': u'This is a comment',
|
||||
'description': 'This is a comment',
|
||||
}, {
|
||||
'pattern': 'blacklisted.net.'
|
||||
}, {
|
||||
@ -230,13 +230,13 @@ class TestCase(base.BaseTestCase):
|
||||
|
||||
pool_fixtures = [
|
||||
{'name': 'Pool-One',
|
||||
'description': u'Pool-One description',
|
||||
'description': 'Pool-One description',
|
||||
'attributes': [{'key': 'scope', 'value': 'public'}],
|
||||
'ns_records': [{'priority': 1, 'hostname': 'ns1.example.org.'},
|
||||
{'priority': 2, 'hostname': 'ns2.example.org.'}]},
|
||||
|
||||
{'name': 'Pool-Two',
|
||||
'description': u'Pool-Two description',
|
||||
'description': 'Pool-Two description',
|
||||
'attributes': [{'key': 'scope', 'value': 'public'}],
|
||||
'ns_records': [{'priority': 1, 'hostname': 'ns1.example.org.'}]},
|
||||
]
|
||||
@ -268,10 +268,10 @@ class TestCase(base.BaseTestCase):
|
||||
pool_target_fixtures = [
|
||||
{'pool_id': default_pool_id,
|
||||
'type': "fake",
|
||||
'description': u"FooBar"},
|
||||
'description': "FooBar"},
|
||||
{'pool_id': default_pool_id,
|
||||
'type': "fake",
|
||||
'description': u"BarFoo"},
|
||||
'description': "BarFoo"},
|
||||
]
|
||||
|
||||
pool_also_notify_fixtures = [
|
||||
@ -421,7 +421,7 @@ class TestCase(base.BaseTestCase):
|
||||
])
|
||||
|
||||
pool.targets = objects.PoolTargetList.from_list([
|
||||
{'type': 'fake', u'description': u"Fake PoolTarget for Tests"}
|
||||
{'type': 'fake', 'description': "Fake PoolTarget for Tests"}
|
||||
])
|
||||
|
||||
# Save the default pool
|
||||
|
@ -169,7 +169,7 @@ class ApiV2BlacklistsTest(ApiV2TestCase):
|
||||
def test_create_invalid_denylist_pattern(self):
|
||||
self.policy({'create_blacklist': '@'})
|
||||
body = {
|
||||
'description': u'This is the description.'
|
||||
'description': 'This is the description.'
|
||||
}
|
||||
|
||||
url = '/blacklists/'
|
||||
|
@ -2488,7 +2488,7 @@ class CentralServiceTest(CentralTestCase):
|
||||
blacklist = self.create_blacklist(fixture=0)
|
||||
|
||||
# Update the Object
|
||||
blacklist.description = u"New Comment"
|
||||
blacklist.description = 'New Comment'
|
||||
|
||||
# Perform the update
|
||||
self.central_service.update_blacklist(self.admin_context, blacklist)
|
||||
@ -2498,7 +2498,7 @@ class CentralServiceTest(CentralTestCase):
|
||||
blacklist.id)
|
||||
|
||||
# Verify that the record was updated correctly
|
||||
self.assertEqual(u"New Comment", blacklist.description)
|
||||
self.assertEqual('New Comment', blacklist.description)
|
||||
|
||||
def test_delete_blacklist(self):
|
||||
# Create a blacklisted zone
|
||||
@ -2691,14 +2691,14 @@ class CentralServiceTest(CentralTestCase):
|
||||
pool = self.create_pool(fixture=0)
|
||||
|
||||
# Update and save the pool
|
||||
pool.description = u'New Comment'
|
||||
pool.description = 'New Comment'
|
||||
self.central_service.update_pool(self.admin_context, pool)
|
||||
|
||||
# Fetch the pool
|
||||
pool = self.central_service.get_pool(self.admin_context, pool.id)
|
||||
|
||||
# Verify that the pool was updated correctly
|
||||
self.assertEqual(u"New Comment", pool.description)
|
||||
self.assertEqual('New Comment', pool.description)
|
||||
|
||||
def test_update_pool_add_ns_record(self):
|
||||
# Create a server pool and 3 zones
|
||||
|
@ -76,7 +76,7 @@ class NovaFixedHandlerTest(TestCase, NotificationHandlerMixin):
|
||||
fixture = self.get_notification_fixture('nova', event_type)
|
||||
|
||||
# Set the instance display_name to a string containing UTF8.
|
||||
fixture['payload']['display_name'] = u'Test↟Instance'
|
||||
fixture['payload']['display_name'] = 'Test↟Instance'
|
||||
|
||||
self.assertIn(event_type, self.plugin.get_event_types())
|
||||
|
||||
|
@ -1686,7 +1686,7 @@ class StorageTestCase(object):
|
||||
def test_create_blacklist(self):
|
||||
values = {
|
||||
'pattern': "^([A-Za-z0-9_\\-]+\\.)*example\\.com\\.$",
|
||||
'description': u"This is a comment."
|
||||
'description': 'This is a comment.'
|
||||
}
|
||||
|
||||
result = self.storage.create_blacklist(
|
||||
@ -1861,7 +1861,7 @@ class StorageTestCase(object):
|
||||
'nameservers': [{'host': "192.0.2.1", 'port': 53}],
|
||||
'targets': [{
|
||||
'type': "fake",
|
||||
'description': u"FooBar",
|
||||
'description': 'FooBar',
|
||||
'masters': [{'host': "192.0.2.2",
|
||||
'port': DEFAULT_MDNS_PORT}],
|
||||
'options': [{'key': 'fake_option', 'value': 'fake_value'}],
|
||||
@ -2021,7 +2021,7 @@ class StorageTestCase(object):
|
||||
'nameservers': [{'host': "192.0.2.1", 'port': 53}],
|
||||
'targets': [{
|
||||
'type': "fake",
|
||||
'description': u"FooBar",
|
||||
'description': 'FooBar',
|
||||
'masters': [{'host': "192.0.2.2",
|
||||
'port': DEFAULT_MDNS_PORT}],
|
||||
'options': [{'key': 'fake_option', 'value': 'fake_value'}],
|
||||
@ -2046,13 +2046,13 @@ class StorageTestCase(object):
|
||||
'nameservers': [{'host': "192.0.2.5", 'port': 53}],
|
||||
'targets': [{
|
||||
'type': "fake",
|
||||
'description': u"NewFooBar",
|
||||
'description': 'NewFooBar',
|
||||
'masters': [{'host': "192.0.2.2",
|
||||
'port': DEFAULT_MDNS_PORT}],
|
||||
'options': [{'key': 'fake_option', 'value': 'fake_value'}],
|
||||
}, {
|
||||
'type': "fake",
|
||||
'description': u"FooBar2",
|
||||
'description': 'FooBar2',
|
||||
'masters': [{'host': "192.0.2.7", 'port': 5355}],
|
||||
'options': [{'key': 'fake_option', 'value': 'new_fake_value'}],
|
||||
}],
|
||||
@ -2598,7 +2598,8 @@ class StorageTestCase(object):
|
||||
|
||||
expected = self.create_pool_target(pool, fixture=0)
|
||||
|
||||
criterion = dict(description=expected['description'] + u"NOT FOUND")
|
||||
criterion = dict(description=expected['description'] + ''
|
||||
'NOT FOUND')
|
||||
|
||||
with testtools.ExpectedException(exceptions.PoolTargetNotFound):
|
||||
self.storage.find_pool_target(self.admin_context, criterion)
|
||||
|
@ -109,7 +109,7 @@ class AkamaiBackendTestCase(oslotest.base.BaseTestCase):
|
||||
json={
|
||||
'comment': 'Created by Designate for Tenant %s' % project_id,
|
||||
'masters': ['192.168.1.1', '192.168.1.2'],
|
||||
'type': 'secondary', 'zone': u'example.com.'
|
||||
'type': 'secondary', 'zone': 'example.com.'
|
||||
},
|
||||
params={
|
||||
'gid': '777',
|
||||
@ -140,7 +140,7 @@ class AkamaiBackendTestCase(oslotest.base.BaseTestCase):
|
||||
json={
|
||||
'comment': 'Created by Designate for Tenant %s' % project_id,
|
||||
'masters': ['192.168.1.1', '192.168.1.2'],
|
||||
'type': 'secondary', 'zone': u'example.com.'
|
||||
'type': 'secondary', 'zone': 'example.com.'
|
||||
},
|
||||
params={
|
||||
'gid': '777',
|
||||
@ -450,12 +450,12 @@ class AkamaiBackendTestCase(oslotest.base.BaseTestCase):
|
||||
|
||||
mock_post.assert_has_calls([
|
||||
mock.call(
|
||||
json={'zones': [u'example.com.']},
|
||||
json={'zones': ['example.com.']},
|
||||
params={'force': True},
|
||||
url='https://host_value/config-dns/v2/zones/delete-requests'
|
||||
),
|
||||
mock.call(
|
||||
json={'zones': [u'example.com.']},
|
||||
json={'zones': ['example.com.']},
|
||||
params={'force': False},
|
||||
url='https://host_value/config-dns/v2/zones/delete-requests'
|
||||
)
|
||||
@ -489,12 +489,12 @@ class AkamaiBackendTestCase(oslotest.base.BaseTestCase):
|
||||
|
||||
mock_post.assert_has_calls([
|
||||
mock.call(
|
||||
json={'zones': [u'example.com.']},
|
||||
json={'zones': ['example.com.']},
|
||||
params={'force': True},
|
||||
url='https://host_value/config-dns/v2/zones/delete-requests'
|
||||
),
|
||||
mock.call(
|
||||
json={'zones': [u'example.com.']},
|
||||
json={'zones': ['example.com.']},
|
||||
params={'force': False},
|
||||
url='https://host_value/config-dns/v2/zones/delete-requests'
|
||||
)
|
||||
|
@ -72,7 +72,7 @@ class NS1BackendTestCase(oslotest.base.BaseTestCase):
|
||||
],
|
||||
}
|
||||
self.put_request_json = {
|
||||
'zone': u'example.com',
|
||||
'zone': 'example.com',
|
||||
'secondary': {
|
||||
'enabled': True,
|
||||
'primary_ip': '192.0.2.1',
|
||||
@ -80,7 +80,7 @@ class NS1BackendTestCase(oslotest.base.BaseTestCase):
|
||||
}
|
||||
}
|
||||
self.put_request_tsig_json = {
|
||||
'zone': u'example.com',
|
||||
'zone': 'example.com',
|
||||
'secondary': {
|
||||
'enabled': True,
|
||||
'primary_ip': '192.0.2.1',
|
||||
|
@ -72,9 +72,9 @@ class PDNS4BackendTestCase(oslotest.base.BaseTestCase):
|
||||
self.assertEqual(
|
||||
req_mock.last_request.json(),
|
||||
{
|
||||
'kind': u'slave',
|
||||
'kind': 'slave',
|
||||
'masters': ['192.0.2.1:53', '192.0.2.2:35'],
|
||||
'name': u'example.com.',
|
||||
'name': 'example.com.',
|
||||
}
|
||||
)
|
||||
|
||||
@ -105,9 +105,9 @@ class PDNS4BackendTestCase(oslotest.base.BaseTestCase):
|
||||
self.assertEqual(
|
||||
req_mock.last_request.json(),
|
||||
{
|
||||
'kind': u'slave',
|
||||
'kind': 'slave',
|
||||
'masters': ['[2001:db8::9abc]:53'],
|
||||
'name': u'example.com.',
|
||||
'name': 'example.com.',
|
||||
}
|
||||
)
|
||||
|
||||
@ -133,9 +133,9 @@ class PDNS4BackendTestCase(oslotest.base.BaseTestCase):
|
||||
self.assertEqual(
|
||||
req_mock.last_request.json(),
|
||||
{
|
||||
'kind': u'slave',
|
||||
'kind': 'slave',
|
||||
'masters': ['192.0.2.1:53', '192.0.2.2:35'],
|
||||
'name': u'example.com.',
|
||||
'name': 'example.com.',
|
||||
}
|
||||
)
|
||||
|
||||
@ -204,9 +204,9 @@ class PDNS4BackendTestCase(oslotest.base.BaseTestCase):
|
||||
self.assertEqual(
|
||||
req_mock.last_request.json(),
|
||||
{
|
||||
'kind': u'slave',
|
||||
'kind': 'slave',
|
||||
'masters': ['192.0.2.1:53', '192.0.2.2:35'],
|
||||
'name': u'example.com.',
|
||||
'name': 'example.com.',
|
||||
'slave_tsig_key_ids': ['tsig_key'],
|
||||
}
|
||||
)
|
||||
|
@ -73,64 +73,64 @@ class DesignateYAMLAdapterTest(oslotest.base.BaseTestCase):
|
||||
pool_dict = {
|
||||
'also_notifies': [
|
||||
{
|
||||
'host': u'192.0.2.4',
|
||||
'pool_id': u'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'host': '192.0.2.4',
|
||||
'pool_id': 'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'port': 53,
|
||||
}
|
||||
],
|
||||
'attributes': [],
|
||||
'description': u'Default PowerDNS 4 Pool',
|
||||
'id': u'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'name': u'default',
|
||||
'description': 'Default PowerDNS 4 Pool',
|
||||
'id': 'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'name': 'default',
|
||||
'nameservers': [
|
||||
{
|
||||
'host': u'192.0.2.2',
|
||||
'pool_id': u'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'host': '192.0.2.2',
|
||||
'pool_id': 'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'port': 53,
|
||||
},
|
||||
{
|
||||
'host': u'192.0.2.3',
|
||||
'pool_id': u'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'host': '192.0.2.3',
|
||||
'pool_id': 'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'port': 53,
|
||||
}
|
||||
],
|
||||
'ns_records': [
|
||||
{
|
||||
'hostname': u'ns1-1.example.org.',
|
||||
'pool_id': u'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'hostname': 'ns1-1.example.org.',
|
||||
'pool_id': 'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'priority': 1,
|
||||
},
|
||||
{
|
||||
'hostname': u'ns1-2.example.org.',
|
||||
'pool_id': u'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'hostname': 'ns1-2.example.org.',
|
||||
'pool_id': 'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'priority': 2,
|
||||
}
|
||||
],
|
||||
'provisioner': u'UNMANAGED',
|
||||
'provisioner': 'UNMANAGED',
|
||||
'targets': [
|
||||
{
|
||||
'description': u'PowerDNS 4 Server',
|
||||
'description': 'PowerDNS 4 Server',
|
||||
'masters': [
|
||||
{
|
||||
'host': u'192.0.2.1',
|
||||
'pool_target_id': u'd567d569-2d69-41d5-828d-f7054bb10b5c', # noqa
|
||||
'host': '192.0.2.1',
|
||||
'pool_target_id': 'd567d569-2d69-41d5-828d-f7054bb10b5c', # noqa
|
||||
'port': DEFAULT_MDNS_PORT,
|
||||
}
|
||||
],
|
||||
'options': [
|
||||
{
|
||||
'key': u'api_endpoint',
|
||||
'pool_target_id': u'd567d569-2d69-41d5-828d-f7054bb10b5c', # noqa
|
||||
'value': u'http://192.0.2.1:8081', # noqa
|
||||
'key': 'api_endpoint',
|
||||
'pool_target_id': 'd567d569-2d69-41d5-828d-f7054bb10b5c', # noqa
|
||||
'value': 'http://192.0.2.1:8081', # noqa
|
||||
},
|
||||
{
|
||||
'key': u'api_token',
|
||||
'pool_target_id': u'd567d569-2d69-41d5-828d-f7054bb10b5c', # noqa
|
||||
'value': u'api_key', # noqa
|
||||
'key': 'api_token',
|
||||
'pool_target_id': 'd567d569-2d69-41d5-828d-f7054bb10b5c', # noqa
|
||||
'value': 'api_key', # noqa
|
||||
},
|
||||
],
|
||||
'pool_id': u'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'type': u'pdns4',
|
||||
'pool_id': 'cf2e8eab-76cd-4162-bf76-8aeee3556de0',
|
||||
'type': 'pdns4',
|
||||
}
|
||||
]
|
||||
}
|
||||
|
@ -69,7 +69,7 @@ source_suffix = '.rst'
|
||||
master_doc = 'index'
|
||||
|
||||
# General information about the project.
|
||||
copyright = u'2012, Managed I.T.'
|
||||
copyright = '2012, Managed I.T.'
|
||||
|
||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||
# for a list of supported languages.
|
||||
@ -207,8 +207,8 @@ latex_elements = {
|
||||
# Grouping the document tree into LaTeX files. List of tuples
|
||||
# (source start file, target name, title, author, documentclass [howto/manual]).
|
||||
latex_documents = [
|
||||
('index', 'doc-designate.tex', u'Designate Documentation',
|
||||
u'Designate Developers', 'manual'),
|
||||
('index', 'doc-designate.tex', 'Designate Documentation',
|
||||
'Designate Developers', 'manual'),
|
||||
]
|
||||
|
||||
# The name of an image file (relative to this directory) to place at the top of
|
||||
@ -255,8 +255,8 @@ man_pages = [
|
||||
# (source start file, target name, title, author,
|
||||
# dir menu entry, description, category)
|
||||
texinfo_documents = [
|
||||
('index', 'designate', u'Designate Documentation',
|
||||
u'Managed I.T.', 'designate', 'One line description of project.',
|
||||
('index', 'designate', 'Designate Documentation',
|
||||
'Managed I.T.', 'designate', 'One line description of project.',
|
||||
'Miscellaneous'),
|
||||
]
|
||||
|
||||
|
@ -60,8 +60,8 @@ source_suffix = '.rst'
|
||||
master_doc = 'index'
|
||||
|
||||
# General information about the project.
|
||||
project = u'Designate Release Notes'
|
||||
copyright = u'2015, Designate Developers'
|
||||
project = 'Designate Release Notes'
|
||||
copyright = '2015, Designate Developers'
|
||||
|
||||
# Release notes are versions independent.
|
||||
# The short X.Y version.
|
||||
@ -212,9 +212,9 @@ latex_elements = {
|
||||
# (source start file, target name, title,
|
||||
# author, documentclass [howto, manual, or own class]).
|
||||
latex_documents = [
|
||||
('index', 'DesignateReleaseNotes.tex', u'Designate Release Notes '
|
||||
u'Documentation',
|
||||
u'Designate Developers', 'manual'),
|
||||
('index', 'DesignateReleaseNotes.tex', 'Designate Release Notes '
|
||||
'Documentation',
|
||||
'Designate Developers', 'manual'),
|
||||
]
|
||||
|
||||
# The name of an image file (relative to this directory) to place at the top of
|
||||
@ -243,9 +243,9 @@ latex_documents = [
|
||||
# One entry per manual page. List of tuples
|
||||
# (source start file, name, description, authors, manual section).
|
||||
man_pages = [
|
||||
('index', 'designatereleasenotes', u'Designate Release Notes '
|
||||
u'Documentation',
|
||||
[u'Designate Developers'], 1)
|
||||
('index', 'designatereleasenotes', 'Designate Release Notes '
|
||||
'Documentation',
|
||||
['Designate Developers'], 1)
|
||||
]
|
||||
|
||||
# If true, show URL addresses after external links.
|
||||
@ -258,9 +258,9 @@ man_pages = [
|
||||
# (source start file, target name, title, author,
|
||||
# dir menu entry, description, category)
|
||||
texinfo_documents = [
|
||||
('index', 'DesignateReleaseNotes', u'Designate Release Notes '
|
||||
u'Documentation',
|
||||
u'Designate Developers', 'DesignateReleaseNotes',
|
||||
('index', 'DesignateReleaseNotes', 'Designate Release Notes '
|
||||
'Documentation',
|
||||
'Designate Developers', 'DesignateReleaseNotes',
|
||||
'One line description of project.',
|
||||
'Miscellaneous'),
|
||||
]
|
||||
|
Loading…
Reference in New Issue
Block a user