Pewarta Proxy

📋 Server Request & Proxy Logs

Loading active proxy settings...
Developed by Khairul Adha (adhexa.id)
Mengambil log server...

⚙️ Pengaturan Proxy Target

Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
remove the unconstructable test (not a valid constraint for everything)
  • Loading branch information
gpshead committed Feb 15, 2023
commit fb6454d2a094ae3c2ba17ad259e2da4b4e2ffc5f
10 changes: 2 additions & 8 deletions Lib/test/test_hashlib.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,12 +201,6 @@ def hash_constructors(self):
def is_fips_mode(self):
return get_fips_mode()

def test_types_unconstructable(self):
for h in self.hash_constructors:
implementation = type(h(b'', usedforsecurity=False))
with self.assertRaises(TypeError):
implementation()

def test_hash_array(self):
a = array.array("b", range(10))
for cons in self.hash_constructors:
Expand Down Expand Up @@ -462,9 +456,9 @@ def check_blocksize_name(self, name, block_size=0, digest_size=0,
self.assertEqual(len(m.hexdigest()), 2*digest_size)
self.assertEqual(m.name, name)
# split for sha3_512 / _sha3.sha3 object
self.assertIn(name.split("_")[0], repr(m))
self.assertIn(name.split("_")[0], repr(m).lower())

def test_blocksize_name(self):
def test_blocksize_and_name(self):
self.check_blocksize_name('md5', 64, 16)
self.check_blocksize_name('sha1', 64, 20)
self.check_blocksize_name('sha224', 64, 28)
Expand Down