def test_half_32(case_key, case_data, cases_half_siphash24_32): for i, case in enumerate(cases_half_siphash24_32): output = siphash.half_siphash_32(case_key[:8], case_data[:i], 2, 4) hex_output = binascii.hexlify(output).decode("utf8") assert case == hex_output
def test_half_255255_32(key_size, case_key, case_data): siphash.half_siphash_32(case_key[:key_size], case_data, 255, 255)
def test_half_255255_32(case_key, case_data): siphash.half_siphash_32(case_key, case_data, 255, 255)
def test_half_00_32(key_size, case_key, case_data): siphash.half_siphash_32(case_key[:key_size], case_data, 0, 0)
def test_half_00_32(case_key, case_data): siphash.half_siphash_32(case_key, case_data, 0, 0)