Commit fe04c937 authored by JINMEI Tatuya's avatar JINMEI Tatuya
Browse files

[1288] cleanups for MockDataSrcClient.get_soa:

- use the initialized zone name for the owner instead of the hardcoded one
- removed a redundant return
for now these don't affect the test results, but it's cleaner and may
have a substantial difference in future extensions.
parent 0f76bcdd
......@@ -77,8 +77,8 @@ class MockDataSrcClient:
def get_soa(self): # emulate ZoneIterator.get_soa()
if self._zone_name == Name('nosoa.example.com'):
return None
soa_rrset = RRset(Name('multisoa.example.com'), RRClass.IN(),
RRType.SOA(), RRTTL(3600))
soa_rrset = RRset(self._zone_name, RRClass.IN(), RRType.SOA(),
RRTTL(3600))
soa_rrset.add_rdata(Rdata(RRType.SOA(), RRClass.IN(),
'master.example.com. ' +
'admin.example.com. 1234 ' +
......@@ -88,7 +88,6 @@ class MockDataSrcClient:
'master.example.com. ' +
'admin.example.com. 1300 ' +
'3600 1800 2419200 7200'))
return soa_rrset
return soa_rrset
class MyCCSession(isc.config.ConfigData):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment