From c8ce4650f0908b8d9d7bf7986f0eae1bf7cae2d5 Mon Sep 17 00:00:00 2001 From: Rodrigo Tobar Date: Tue, 23 Jul 2024 15:01:30 +0800 Subject: [PATCH] Add tests for different chunk sizes and offsets The latter in particular is useful to make sure that the different memory alignment code paths in the C code are correct. Signed-off-by: Rodrigo Tobar --- CHANGELOG.md | 1 + test/test_crc32c.py | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8716776..e2c34f8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ * Adding explicit fallthrough annotations in several ``switch`` C statements for clarity, and to avoid potential warnings (#46). +* Run test against different memory alignments. ## [2.4.1] diff --git a/test/test_crc32c.py b/test/test_crc32c.py index 7b9e579..480610a 100644 --- a/test/test_crc32c.py +++ b/test/test_crc32c.py @@ -45,6 +45,11 @@ def ushort_as_bytes(x): def uchar_as_bytes(c): return struct.pack('