@@ -56,7 +56,7 @@ struct test_case {
5656
5757#define TEST_CASE (bytes , zone , caps , num , type , name_base ) \
5858 {(bytes), (zone), (caps), (num), (type), \
59- (name_base "__" #zone "__" #bytes "x" #num)}
59+ ("test_lib_alloc_" name_base "__" #zone "__" #bytes "x" #num)}
6060
6161static struct test_case test_cases [] = {
6262 /*
@@ -236,7 +236,7 @@ static void *alloc(struct test_case *tc)
236236 return mem ;
237237}
238238
239- static void test_alloc_bulk_free (struct test_case * tc )
239+ static void test_lib_alloc_bulk_free (struct test_case * tc )
240240{
241241 void * * all_mem = malloc (sizeof (void * ) * tc -> alloc_num );
242242 int i ;
@@ -254,7 +254,7 @@ static void test_alloc_bulk_free(struct test_case *tc)
254254 rfree (all_mem );
255255}
256256
257- static void test_alloc_immediate_free (struct test_case * tc )
257+ static void test_lib_alloc_immediate_free (struct test_case * tc )
258258{
259259 int i ;
260260
@@ -266,7 +266,7 @@ static void test_alloc_immediate_free(struct test_case *tc)
266266 }
267267}
268268
269- static void test_alloc_zero (struct test_case * tc )
269+ static void test_lib_alloc_zero (struct test_case * tc )
270270{
271271 void * * all_mem = malloc (sizeof (void * ) * tc -> alloc_num );
272272 int i ;
@@ -289,21 +289,21 @@ static void test_alloc_zero(struct test_case *tc)
289289 rfree (all_mem );
290290}
291291
292- static void test_alloc (void * * state )
292+ static void test_lib_alloc (void * * state )
293293{
294294 struct test_case * tc = * ((struct test_case * * )state );
295295
296296 switch (tc -> type ) {
297297 case TEST_BULK :
298- test_alloc_bulk_free (tc );
298+ test_lib_alloc_bulk_free (tc );
299299 break ;
300300
301301 case TEST_ZERO :
302- test_alloc_zero (tc );
302+ test_lib_alloc_zero (tc );
303303 break ;
304304
305305 case TEST_IMMEDIATE_FREE :
306- test_alloc_immediate_free (tc );
306+ test_lib_alloc_immediate_free (tc );
307307 break ;
308308 }
309309}
@@ -318,7 +318,7 @@ int main(void)
318318 struct CMUnitTest * t = & tests [i ];
319319
320320 t -> name = test_cases [i ].name ;
321- t -> test_func = test_alloc ;
321+ t -> test_func = test_lib_alloc ;
322322 t -> initial_state = & test_cases [i ];
323323 t -> setup_func = NULL ;
324324 t -> teardown_func = NULL ;
0 commit comments