diff options
| author | Robert Clausecker <fuz@FreeBSD.org> | 2025-11-18 17:33:12 +0000 |
|---|---|---|
| committer | Robert Clausecker <fuz@FreeBSD.org> | 2025-11-30 19:21:52 +0000 |
| commit | 2fb8cbc6ef1b3cc6cd60e5db07f8305623f9b044 (patch) | |
| tree | 1fcb68705ab2799af1c6150e6d64942423fdf8d2 /lib/libc/tests/stdbit/Makefile | |
| parent | d790b16bbf0c3055ef00200d01659dfb3c0e5e5e (diff) | |
libc/tests: add stdbit test framework and unit tests
This adds unit tests for all 70 functions in <stdbit.h>.
I'm sorry for the test framework, but it makes it so I don't
have to write 70 unit tests by hand.
Reviewed by: adrian, des
Approved by: markj (mentor)
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D53660
Diffstat (limited to 'lib/libc/tests/stdbit/Makefile')
| -rw-r--r-- | lib/libc/tests/stdbit/Makefile | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/lib/libc/tests/stdbit/Makefile b/lib/libc/tests/stdbit/Makefile new file mode 100644 index 000000000000..37450056007a --- /dev/null +++ b/lib/libc/tests/stdbit/Makefile @@ -0,0 +1,19 @@ +# ensure libc functions are tested, not clang's builtins +CFLAGS+= -fno-builtin + +ATF_TESTS_C+= stdc_bit_ceil_test \ + stdc_bit_floor_test \ + stdc_bit_width_test \ + stdc_count_ones_test \ + stdc_count_zeros_test \ + stdc_first_leading_one_test \ + stdc_first_leading_zero_test \ + stdc_first_trailing_one_test \ + stdc_first_trailing_zero_test \ + stdc_has_single_bit_test \ + stdc_leading_ones_test \ + stdc_leading_zeros_test \ + stdc_trailing_ones_test \ + stdc_trailing_zeros_test + +.include <bsd.test.mk> |
