From dfdf53df99c8f59e5e3a4296c455041bee96a88d Mon Sep 17 00:00:00 2001 From: jvoisin Date: Thu, 30 Apr 2026 17:50:27 +0200 Subject: Improve coverage for wmemcpy and wmemmove Like it's already done for memcpy and memmove. Add tests as well, to prove that nothing broke. --- tests/test_wmemmove_dynamic_read.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 tests/test_wmemmove_dynamic_read.c (limited to 'tests/test_wmemmove_dynamic_read.c') diff --git a/tests/test_wmemmove_dynamic_read.c b/tests/test_wmemmove_dynamic_read.c new file mode 100644 index 0000000..05e315b --- /dev/null +++ b/tests/test_wmemmove_dynamic_read.c @@ -0,0 +1,16 @@ +#include "common.h" + +#include + +int main(int argc, char** argv) { + wchar_t buffer[12] = {0}; + wmemmove(buffer, L"αβγδεζηθικ", sizeof(buffer) / sizeof(wchar_t) - 1); + printf("%ls\n", buffer); + + CHK_FAIL_START + wmemmove(buffer, L"αβγδεζ", argc); + CHK_FAIL_END + + printf("%ls\n", buffer); + return ret; +} -- cgit v1.3