MCPcopy Create free account
hub / github.com/rthalley/dnspython / test_replacement_commit

Function test_replacement_commit

tests/test_transaction.py:574–584  ·  view source on GitHub ↗
(zone)

Source from the content-addressed store, hash-verified

572
573
574def test_replacement_commit(zone):
575 rds = dns.rdataset.from_text("in", "a", 300, "1.2.3.4", "5.6.7.8")
576 expected = {}
577 expected[(dns.name.empty, rds.rdtype, rds.covers)] = rds
578 with zone.writer(True) as txn:
579 txn.replace(dns.name.empty, rds)
580 with zone.reader() as txn:
581 actual = {}
582 for name, rdataset in txn:
583 actual[(name, rdataset.rdtype, rdataset.covers)] = rdataset
584 assert actual == expected
585
586
587def test_replacement_get(zone):

Callers

nothing calls this directly

Calls 4

from_textMethod · 0.45
writerMethod · 0.45
replaceMethod · 0.45
readerMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…