Fix memory tests

This commit is contained in:
2026-04-04 19:45:29 -05:00
parent 98d70b96d1
commit 4cd3355ef1

View File

@@ -313,8 +313,8 @@ static void test_memoryCompare(void **state) {
assert_int_equal(memoryCompare(a, a, size), 0); assert_int_equal(memoryCompare(a, a, size), 0);
assert_int_equal(memoryCompare(b, b, size), 0); assert_int_equal(memoryCompare(b, b, size), 0);
// Cannot compare 0 bytes // Comparison of 0 bytes is always true
expect_assert_failure(memoryCompare(a, b, 0)); assert_true(memoryCompare(a, b, 0));
// Compare different sizes (should assert, so we only test the API contract) // Compare different sizes (should assert, so we only test the API contract)
// Not possible with current API, as size is explicit, but document intent. // Not possible with current API, as size is explicit, but document intent.