diff --git a/tests/test_pycrypto_keys.py b/tests/test_pycrypto_keys.py index 667e93fa..241ef74a 100755 --- a/tests/test_pycrypto_keys.py +++ b/tests/test_pycrypto_keys.py @@ -84,7 +84,6 @@ def test_create_rsa_signature(self): pycrypto.create_rsa_signature, '', data) # Check for invalid 'data'. - print(repr(private_rsa)) pycrypto.create_rsa_signature(private_rsa, '') self.assertRaises(tuf.CryptoError, diff --git a/tests/test_updater.py b/tests/test_updater.py index 682ee6a7..cbf6c63a 100755 --- a/tests/test_updater.py +++ b/tests/test_updater.py @@ -443,8 +443,6 @@ def test_2__import_delegations(self): self.repository_updater.metadata['current']['targets']\ ['delegations']['keys'][existing_keyid]['keyid'] = '123' - print(repr(self.repository_updater.metadata['current']['targets']\ - ['delegations']['keys'][existing_keyid]['keyid'])) self.repository_updater._import_delegations('targets') #self.assertRaises(tuf.Error, self.repository_updater._import_delegations, # 'targets') @@ -1227,7 +1225,7 @@ def test_9__get_target_hash(self): def test_10__hard_check_file_length(self): # Test for exception if file object is not equal to trusted file length. temp_file_object = tuf.util.TempFile() - temp_file_object.write('X') + temp_file_object.write(b'X') temp_file_object.seek(0) self.assertRaises(tuf.DownloadLengthMismatchError, self.repository_updater._hard_check_file_length, @@ -1240,7 +1238,7 @@ def test_10__hard_check_file_length(self): def test_10__soft_check_file_length(self): # Test for exception if file object is not equal to trusted file length. temp_file_object = tuf.util.TempFile() - temp_file_object.write('XXX') + temp_file_object.write(b'XXX') temp_file_object.seek(0) self.assertRaises(tuf.DownloadLengthMismatchError, self.repository_updater._soft_check_file_length, diff --git a/tests/test_util.py b/tests/test_util.py index 5c897a49..b5ce3694 100755 --- a/tests/test_util.py +++ b/tests/test_util.py @@ -241,7 +241,7 @@ def test_A6_tempfile_decompress_temp_file_object(self): # Test decompression of invalid gzip file. temp_file = tuf.util.TempFile() - temp_file.write('bad zip') + temp_file.write(b'bad zip') contents = temp_file.read() self.assertRaises(tuf.DecompressionError, temp_file.decompress_temp_file_object, 'gzip')