def test_crc32_force_text(self): filepath = os.path.join(project_dir, "tests", "testfile") crc32 = cct.crc32(filepath, force_text=True) self.assertNotEqual(crc32, 602403306)
def test_crc32_file(self): filepath = os.path.join(project_dir, "tests", "testfile") crc32 = cct.crc32(filepath) self.assertEqual(crc32, 602403306)
def test_crc32_int(self): crc32 = cct.crc32(42) self.assertEqual(crc32, 841265288)
def test_crc32_bytes(self): crc32 = cct.crc32(b'Test Text') self.assertEqual(crc32, 1739839371)
def test_crc32_string(self): crc32 = cct.crc32("Test Text") self.assertEqual(crc32, 1739839371)