mirror of
https://github.com/github/octodns.git
synced 2024-05-11 05:55:00 +00:00
f-strings for the rest of the tests
This commit is contained in:
@@ -14,7 +14,7 @@ class TestEnvVarSource(TestCase):
|
||||
source = EnvVarSource('testid', envvar, 'recordname', ttl=120)
|
||||
with self.assertRaises(EnvironmentVariableNotFoundException) as ctx:
|
||||
source._read_variable()
|
||||
msg = 'Unknown environment variable {}'.format(envvar)
|
||||
msg = f'Unknown environment variable {envvar}'
|
||||
self.assertEquals(msg, text_type(ctx.exception))
|
||||
|
||||
with patch.dict('os.environ', {envvar: 'testvalue'}):
|
||||
@@ -35,7 +35,7 @@ class TestEnvVarSource(TestCase):
|
||||
self.assertEquals(1, len(zone.records))
|
||||
record = list(zone.records)[0]
|
||||
self.assertEquals(name, record.name)
|
||||
self.assertEquals('{}.{}'.format(name, zone_name), record.fqdn)
|
||||
self.assertEquals(f'{name}.{zone_name}', record.fqdn)
|
||||
self.assertEquals('TXT', record._type)
|
||||
self.assertEquals(1, len(record.values))
|
||||
self.assertEquals(value, record.values[0])
|
||||
|
Reference in New Issue
Block a user