]> git.ipfire.org Git - thirdparty/dnspython.git/commitdiff
remove or comment out some prints in tests
authorBob Halley <halley@dnspython.org>
Sun, 23 May 2021 17:06:07 +0000 (10:06 -0700)
committerBob Halley <halley@dnspython.org>
Sun, 23 May 2021 17:06:07 +0000 (10:06 -0700)
tests/test_processing_order.py
tests/test_rdataset.py
tests/test_transaction.py
tests/test_xfr.py
tests/util.py

index 45a90cff526442bcd216f32dcdde07bad75137e6..4be695a0b1d2d20dd629aca1523e29f2cd86ad69 100644 (file)
@@ -80,14 +80,12 @@ def test_processing_order_empty():
 def test_processing_singleton_priority():
     rds = dns.rdataset.from_text('in', 'mx', 300, '10 a')
     po = rds.processing_order()
-    print(po)
     assert po == [rds[0]]
 
 
 def test_processing_singleton_weighted():
     rds = dns.rdataset.from_text('in', 'srv', 300, '1 10 1234 a')
     po = rds.processing_order()
-    print(po)
     assert po == [rds[0]]
 
 
index 4710e2a9b11d59b3bf9d36fd0227d54ba66b7cde..69ec6ded334d7285930a6d1c0c5db54d9d21b235 100644 (file)
@@ -117,7 +117,6 @@ class RdatasetTestCase(unittest.TestCase):
                                      '2143 foo Ym9ndXM=')
         # Using startswith as I don't care about the repr of the rdata,
         # just the covers
-        print(repr(rds))
         self.assertTrue(repr(rds).startswith(
             '<DNS IN RRSIG(NSEC) rdataset:'))
 
index bb69b7148f0179ce393dfa08ef09075e8c8c4835..9ac9f5601352018ee5a0486ae62902e33502adcf 100644 (file)
@@ -322,7 +322,7 @@ def test_explicit_rollback_and_commit(zone):
         with zone.writer() as txn:
             txn.rollback()
             for rdataset in txn:
-                print(rdataset)
+                pass
 
 def test_zone_changed(zone):
     # Read-only is not changed!
@@ -417,7 +417,6 @@ def test_write_after_rollback(zone):
 
 def test_zone_get_deleted(zone):
     with zone.writer() as txn:
-        print(zone.to_text())
         ns1 = dns.name.from_text('ns1', None)
         assert txn.get(ns1, dns.rdatatype.A) is not None
         txn.delete(ns1)
@@ -471,9 +470,9 @@ class ExpectedException(Exception):
     pass
 
 def test_zone_rollback(zone):
+    a99 = dns.name.from_text('a99.example.')
     try:
         with zone.writer() as txn:
-            a99 = dns.name.from_text('a99.example.')
             rds = dns.rdataset.from_text('in', 'a', 300, '10.0.0.99')
             txn.add(a99, rds)
             assert txn.name_exists(a99)
index 7429fa35a6e2199920b7abed860c0de81594bc89..3fa1eba00491182aa37aed81c1aed8671555d5ad 100644 (file)
@@ -600,7 +600,6 @@ def test_extract_serial_from_query():
     assert s is None
     assert s == xs
     (q, s) = dns.xfr.make_query(z, serial=10)
-    print(q)
     xs = dns.xfr.extract_serial_from_query(q)
     assert s == 10
     assert s == xs
index 644a88a10a25504ea09ad4e9096052d737a722f7..e8c13630847ebb76c65784c491a8fb02b339bd50 100644 (file)
@@ -33,8 +33,8 @@ def check_enum_exports(module, eq_callback, only=None):
     """Make sure module exports all mnemonics from enums"""
     for attr in enumerate_module(module, enum.Enum):
         if only is not None and attr not in only:
-            print('SKIP', attr)
+            #print('SKIP', attr)
             continue
         for flag, value in attr.__members__.items():
-            print(module, flag, value)
+            #print(module, flag, value)
             eq_callback(getattr(module, flag), value)