crt: tests: update t_aligned_alloc [2/2]

On aarch64, due to buggy `_aligned_realloc`, some subtests were skipped
(when `BROKEN_REALLOC_SHRINK` is defined to non-zero).

Instead of entirely skipping those subtests, do the test, and in case if it
fails, exit only if that test was not expected to fail. This is achieved by
extening `TEST` and `TEST_MEM` macros to take an extra argument which indicates
whether this subtest is expected to fail.

For subtests which were previously skipped when `BROKEN_REALLOC_SHRINK` is
defined to non-zero, the extra argument to `TEST` and `TEST_MEM` is
`BROKEN_REALLOC_SHRINK` itself; subtest is expected to fail when
`BROKEN_REALLOC_SHRINK` is non-zero.

For other subtests, the extra argument is zero; subtest is not expected to fail.

Signed-off-by: Kirill Makurin <maiddaisuki@outlook.com>
Signed-off-by: LIU Hao <lh_mouse@126.com>
1 file changed