1 /*
2 * Copyright © 2023 Intel Corporation
3 * SPDX-License-Identifier: MIT
4 */
5
6 #include <gtest/gtest.h>
7
8 #include "test_common.h"
9
10 #define ANV_C_TEST(S, N, C) extern "C" void C(void); TEST(S, N) { C(); }
11
12 ANV_C_TEST(StatePool, Regular, state_pool_test);
13 ANV_C_TEST(StatePool, FreeListOnly, state_pool_free_list_only_test);
14 ANV_C_TEST(StatePool, MaxSizeOverLimit, state_pool_max_size_over_limit);
15 ANV_C_TEST(StatePool, MaxSizeWithinLimit, state_pool_max_size_within_limit);
16 ANV_C_TEST(StatePool, NoFree, state_pool_no_free_test);
17 ANV_C_TEST(StatePool, Padding, state_pool_padding_test);
18
19 ANV_C_TEST(BlockPool, NoFree, block_pool_no_free_test);
20 ANV_C_TEST(BlockPool, GrowFirst, block_pool_grow_first_test);
21 ANV_C_TEST(BlockPool, MaxSize, block_pool_max_size);
22
FAIL_IN_GTEST(const char * file_path,unsigned line_number,const char * msg)23 extern "C" void FAIL_IN_GTEST(const char *file_path, unsigned line_number, const char *msg) {
24 GTEST_FAIL_AT(file_path, line_number) << msg;
25 }
26