Merge "Remove unicode prefix from code"

This commit is contained in:
Zuul
2025-07-06 15:15:33 +00:00
committed by Gerrit Code Review
2 changed files with 8 additions and 8 deletions

View File

@@ -36,9 +36,9 @@ IPV6_PATTERN_BASE = ('('
'([0-9a-fA-F]{1,4}:){1,4}:' '([0-9a-fA-F]{1,4}:){1,4}:'
'((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\.){3,3}' '((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\.){3,3}'
'(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))') '(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))')
IPV6_PATTERN = EPSILON_PATTERN + u'|^' + IPV6_PATTERN_BASE + u'$' IPV6_PATTERN = EPSILON_PATTERN + '|^' + IPV6_PATTERN_BASE + '$'
CIDRV6_PATTERN = EPSILON_PATTERN + u'|^(' + IPV6_PATTERN_BASE + \ CIDRV6_PATTERN = EPSILON_PATTERN + '|^(' + IPV6_PATTERN_BASE + \
'(/(1[0-2][0-8]|[1-9]?[0-9]))' + u')$' '(/(1[0-2][0-8]|[1-9]?[0-9]))' + ')$'
SCHEMA = { SCHEMA = {
"PLUGIN_ACTIVATE": {"Implements": ["NetworkDriver"]}, "PLUGIN_ACTIVATE": {"Implements": ["NetworkDriver"]},
@@ -206,7 +206,7 @@ COMMONS = {
'example': 'dfe39822-ad5e-40bd-babd-3954113b3687' 'example': 'dfe39822-ad5e-40bd-babd-3954113b3687'
} }
}, },
'$schema': 'http://json-schema.org/draft-04/hyper-schema', '$schema': 'https://json-schema.org/draft-04/hyper-schema',
'type': 'object', 'type': 'object',
'id': 'schemata/commons' 'id': 'schemata/commons'
} }
@@ -222,7 +222,7 @@ NETWORK_CREATE_SCHEMA = {
'title': 'Create network', 'title': 'Create network',
'required': ['NetworkID', 'IPv4Data', 'IPv6Data', 'Options'], 'required': ['NetworkID', 'IPv4Data', 'IPv6Data', 'Options'],
'definitions': {'commons': {}}, 'definitions': {'commons': {}},
'$schema': 'http://json-schema.org/draft-04/hyper-schema', '$schema': 'https://json-schema.org/draft-04/hyper-schema',
'type': 'object', 'type': 'object',
'properties': { 'properties': {
'NetworkID': { 'NetworkID': {
@@ -296,7 +296,7 @@ NETWORK_JOIN_SCHEMA = {
} }
}, },
'definitions': {'commons': {}}, 'definitions': {'commons': {}},
'$schema': 'http://json-schema.org/draft-04/hyper-schema', '$schema': 'https://json-schema.org/draft-04/hyper-schema',
'type': 'object', 'type': 'object',
} }

View File

@@ -64,8 +64,8 @@ class TestUtils(trove_testtools.TestCase):
'/usr/bin/foo', log_output_on_error=True) '/usr/bin/foo', log_output_on_error=True)
utils.LOG.error.assert_called_with( utils.LOG.error.assert_called_with(
u"Command '%(cmd)s' failed. %(description)s Exit code: " "Command '%(cmd)s' failed. %(description)s Exit code: "
u"%(exit_code)s\nstderr: %(stderr)s\nstdout: %(stdout)s", "%(exit_code)s\nstderr: %(stderr)s\nstdout: %(stdout)s",
{'description': 'test-desc', 'stderr': 'err', 'exit_code': 42, {'description': 'test-desc', 'stderr': 'err', 'exit_code': 42,
'stdout': 'out', 'cmd': 'test'}) 'stdout': 'out', 'cmd': 'test'})