summaryrefslogtreecommitdiff
path: root/src/tests/eina/eina_test_value.c
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@osg.samsung.com>2018-03-26 14:19:28 -0400
committerStefan Schmidt <stefan@osg.samsung.com>2018-04-05 11:10:25 +0200
commitadc601aca2f0a16784af36bf6ae7dd20eeb33202 (patch)
treecac0a78fa40e88abb028b06d985c28bf89da269c /src/tests/eina/eina_test_value.c
parentb340b5e49ccae48a7d5adbbfa301af39e232348c (diff)
tests: add instrumentation to existing tests to find slow tests
efl_check.h must be included and the EFL_START/END_TEST macros must be used in place of normal START/END_TEST macros timing is enabled when TIMING_ENABLED is set https://phab.enlightenment.org/w/improve_tests/ Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com>
Diffstat (limited to 'src/tests/eina/eina_test_value.c')
-rw-r--r--src/tests/eina/eina_test_value.c108
1 files changed, 54 insertions, 54 deletions
diff --git a/src/tests/eina/eina_test_value.c b/src/tests/eina/eina_test_value.c
index 15cf35888e..76b9a0b4c1 100644
--- a/src/tests/eina/eina_test_value.c
+++ b/src/tests/eina/eina_test_value.c
@@ -31,7 +31,7 @@
31#define FP_ERR (1) 31#define FP_ERR (1)
32#define CHECK_FP(a, b) ((a - b) <= FP_ERR) 32#define CHECK_FP(a, b) ((a - b) <= FP_ERR)
33 33
34START_TEST(eina_value_test_simple) 34EFL_START_TEST(eina_value_test_simple)
35{ 35{
36 Eina_Value *value; 36 Eina_Value *value;
37 char c; 37 char c;
@@ -128,9 +128,9 @@ START_TEST(eina_value_test_simple)
128 eina_value_free(value); 128 eina_value_free(value);
129 eina_shutdown(); 129 eina_shutdown();
130} 130}
131END_TEST 131EFL_END_TEST
132 132
133START_TEST(eina_value_test_compare) 133EFL_START_TEST(eina_value_test_compare)
134{ 134{
135 Eina_Value *a, *b; 135 Eina_Value *a, *b;
136 136
@@ -432,9 +432,9 @@ START_TEST(eina_value_test_compare)
432 eina_value_free(b); 432 eina_value_free(b);
433 eina_shutdown(); 433 eina_shutdown();
434} 434}
435END_TEST 435EFL_END_TEST
436 436
437START_TEST(eina_value_test_string) 437EFL_START_TEST(eina_value_test_string)
438{ 438{
439 Eina_Value *value; 439 Eina_Value *value;
440 const char *s; 440 const char *s;
@@ -461,9 +461,9 @@ START_TEST(eina_value_test_string)
461 eina_value_free(value); 461 eina_value_free(value);
462 eina_shutdown(); 462 eina_shutdown();
463} 463}
464END_TEST 464EFL_END_TEST
465 465
466START_TEST(eina_value_test_pvariant) 466EFL_START_TEST(eina_value_test_pvariant)
467{ 467{
468 Eina_Value *value; 468 Eina_Value *value;
469 char c, in_c; 469 char c, in_c;
@@ -592,9 +592,9 @@ START_TEST(eina_value_test_pvariant)
592 eina_value_free(value); 592 eina_value_free(value);
593 eina_shutdown(); 593 eina_shutdown();
594} 594}
595END_TEST 595EFL_END_TEST
596 596
597START_TEST(eina_value_test_to_string) 597EFL_START_TEST(eina_value_test_to_string)
598{ 598{
599 Eina_Value *value; 599 Eina_Value *value;
600 char c, in_c; 600 char c, in_c;
@@ -797,9 +797,9 @@ START_TEST(eina_value_test_to_string)
797 eina_value_free(value); 797 eina_value_free(value);
798 eina_shutdown(); 798 eina_shutdown();
799} 799}
800END_TEST 800EFL_END_TEST
801 801
802START_TEST(eina_value_test_to_binbuf) 802EFL_START_TEST(eina_value_test_to_binbuf)
803{ 803{
804 Eina_Value *value; 804 Eina_Value *value;
805 char c, in_c; 805 char c, in_c;
@@ -861,9 +861,9 @@ START_TEST(eina_value_test_to_binbuf)
861 eina_value_free(value); 861 eina_value_free(value);
862 eina_shutdown(); 862 eina_shutdown();
863} 863}
864END_TEST 864EFL_END_TEST
865 865
866START_TEST(eina_value_test_convert_char) 866EFL_START_TEST(eina_value_test_convert_char)
867{ 867{
868 Eina_Value *value, conv; 868 Eina_Value *value, conv;
869 char c; 869 char c;
@@ -992,9 +992,9 @@ START_TEST(eina_value_test_convert_char)
992 eina_value_free(value); 992 eina_value_free(value);
993 eina_shutdown(); 993 eina_shutdown();
994} 994}
995END_TEST 995EFL_END_TEST
996 996
997START_TEST(eina_value_test_convert_uchar) 997EFL_START_TEST(eina_value_test_convert_uchar)
998{ 998{
999 Eina_Value *value, conv; 999 Eina_Value *value, conv;
1000 char c; 1000 char c;
@@ -1107,9 +1107,9 @@ START_TEST(eina_value_test_convert_uchar)
1107 eina_value_free(value); 1107 eina_value_free(value);
1108 eina_shutdown(); 1108 eina_shutdown();
1109} 1109}
1110END_TEST 1110EFL_END_TEST
1111 1111
1112START_TEST(eina_value_test_convert_short) 1112EFL_START_TEST(eina_value_test_convert_short)
1113{ 1113{
1114 Eina_Value *value, conv; 1114 Eina_Value *value, conv;
1115 short s; 1115 short s;
@@ -1240,9 +1240,9 @@ START_TEST(eina_value_test_convert_short)
1240 eina_value_free(value); 1240 eina_value_free(value);
1241 eina_shutdown(); 1241 eina_shutdown();
1242} 1242}
1243END_TEST 1243EFL_END_TEST
1244 1244
1245START_TEST(eina_value_test_convert_ushort) 1245EFL_START_TEST(eina_value_test_convert_ushort)
1246{ 1246{
1247 Eina_Value *value, conv; 1247 Eina_Value *value, conv;
1248 int i; 1248 int i;
@@ -1343,9 +1343,9 @@ START_TEST(eina_value_test_convert_ushort)
1343 eina_value_free(value); 1343 eina_value_free(value);
1344 eina_shutdown(); 1344 eina_shutdown();
1345} 1345}
1346END_TEST 1346EFL_END_TEST
1347 1347
1348START_TEST(eina_value_test_convert_int) 1348EFL_START_TEST(eina_value_test_convert_int)
1349{ 1349{
1350 Eina_Value *value, conv; 1350 Eina_Value *value, conv;
1351 int i; 1351 int i;
@@ -1474,9 +1474,9 @@ START_TEST(eina_value_test_convert_int)
1474 eina_value_free(value); 1474 eina_value_free(value);
1475 eina_shutdown(); 1475 eina_shutdown();
1476} 1476}
1477END_TEST 1477EFL_END_TEST
1478 1478
1479START_TEST(eina_value_test_convert_uint) 1479EFL_START_TEST(eina_value_test_convert_uint)
1480{ 1480{
1481 Eina_Value *value, conv; 1481 Eina_Value *value, conv;
1482 unsigned int ui; 1482 unsigned int ui;
@@ -1561,9 +1561,9 @@ START_TEST(eina_value_test_convert_uint)
1561 eina_value_free(value); 1561 eina_value_free(value);
1562 eina_shutdown(); 1562 eina_shutdown();
1563} 1563}
1564END_TEST 1564EFL_END_TEST
1565 1565
1566START_TEST(eina_value_test_convert_long) 1566EFL_START_TEST(eina_value_test_convert_long)
1567{ 1567{
1568 Eina_Value *value, conv; 1568 Eina_Value *value, conv;
1569 char c; 1569 char c;
@@ -1712,9 +1712,9 @@ START_TEST(eina_value_test_convert_long)
1712 eina_value_free(value); 1712 eina_value_free(value);
1713 eina_shutdown(); 1713 eina_shutdown();
1714} 1714}
1715END_TEST 1715EFL_END_TEST
1716 1716
1717START_TEST(eina_value_test_convert_ulong) 1717EFL_START_TEST(eina_value_test_convert_ulong)
1718{ 1718{
1719 Eina_Value *value, conv; 1719 Eina_Value *value, conv;
1720 char c; 1720 char c;
@@ -1841,9 +1841,9 @@ START_TEST(eina_value_test_convert_ulong)
1841 eina_value_free(value); 1841 eina_value_free(value);
1842 eina_shutdown(); 1842 eina_shutdown();
1843} 1843}
1844END_TEST 1844EFL_END_TEST
1845 1845
1846START_TEST(eina_value_test_convert_float) 1846EFL_START_TEST(eina_value_test_convert_float)
1847{ 1847{
1848 Eina_Value *value, conv; 1848 Eina_Value *value, conv;
1849 char c; 1849 char c;
@@ -2016,9 +2016,9 @@ START_TEST(eina_value_test_convert_float)
2016 eina_shutdown(); 2016 eina_shutdown();
2017 2017
2018} 2018}
2019END_TEST 2019EFL_END_TEST
2020 2020
2021START_TEST(eina_value_test_array) 2021EFL_START_TEST(eina_value_test_array)
2022{ 2022{
2023 Eina_Value *value, other; 2023 Eina_Value *value, other;
2024 Eina_Value_Array desc; 2024 Eina_Value_Array desc;
@@ -2128,9 +2128,9 @@ START_TEST(eina_value_test_array)
2128 eina_value_free(value); 2128 eina_value_free(value);
2129 eina_shutdown(); 2129 eina_shutdown();
2130} 2130}
2131END_TEST 2131EFL_END_TEST
2132 2132
2133START_TEST(eina_value_test_list) 2133EFL_START_TEST(eina_value_test_list)
2134{ 2134{
2135 Eina_Value *value, other; 2135 Eina_Value *value, other;
2136 Eina_Value_List desc; 2136 Eina_Value_List desc;
@@ -2238,9 +2238,9 @@ START_TEST(eina_value_test_list)
2238 eina_value_free(value); 2238 eina_value_free(value);
2239 eina_shutdown(); 2239 eina_shutdown();
2240} 2240}
2241END_TEST 2241EFL_END_TEST
2242 2242
2243START_TEST(eina_value_test_hash) 2243EFL_START_TEST(eina_value_test_hash)
2244{ 2244{
2245 Eina_Value *value, other; 2245 Eina_Value *value, other;
2246 Eina_Value_Hash desc; 2246 Eina_Value_Hash desc;
@@ -2358,10 +2358,10 @@ START_TEST(eina_value_test_hash)
2358 eina_value_free(value); 2358 eina_value_free(value);
2359 eina_shutdown(); 2359 eina_shutdown();
2360} 2360}
2361END_TEST 2361EFL_END_TEST
2362 2362
2363 2363
2364START_TEST(eina_value_test_timeval) 2364EFL_START_TEST(eina_value_test_timeval)
2365{ 2365{
2366 Eina_Value *value, other; 2366 Eina_Value *value, other;
2367 struct timeval itv, otv; 2367 struct timeval itv, otv;
@@ -2442,10 +2442,10 @@ START_TEST(eina_value_test_timeval)
2442 eina_value_free(value); 2442 eina_value_free(value);
2443 eina_shutdown(); 2443 eina_shutdown();
2444} 2444}
2445END_TEST 2445EFL_END_TEST
2446 2446
2447 2447
2448START_TEST(eina_value_test_blob) 2448EFL_START_TEST(eina_value_test_blob)
2449{ 2449{
2450 Eina_Value *value, other; 2450 Eina_Value *value, other;
2451 Eina_Value_Blob in, out; 2451 Eina_Value_Blob in, out;
@@ -2531,10 +2531,10 @@ START_TEST(eina_value_test_blob)
2531 eina_value_free(value); 2531 eina_value_free(value);
2532 eina_shutdown(); 2532 eina_shutdown();
2533} 2533}
2534END_TEST 2534EFL_END_TEST
2535 2535
2536 2536
2537START_TEST(eina_value_test_struct) 2537EFL_START_TEST(eina_value_test_struct)
2538{ 2538{
2539 struct mybigst { 2539 struct mybigst {
2540 int a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, x; 2540 int a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, x;
@@ -2717,10 +2717,10 @@ START_TEST(eina_value_test_struct)
2717 eina_value_free(value); 2717 eina_value_free(value);
2718 eina_shutdown(); 2718 eina_shutdown();
2719} 2719}
2720END_TEST 2720EFL_END_TEST
2721 2721
2722 2722
2723START_TEST(eina_value_test_array_of_struct) 2723EFL_START_TEST(eina_value_test_array_of_struct)
2724{ 2724{
2725 struct myst { 2725 struct myst {
2726 int a, b, c; 2726 int a, b, c;
@@ -2794,9 +2794,9 @@ START_TEST(eina_value_test_array_of_struct)
2794 eina_value_free(value); 2794 eina_value_free(value);
2795 eina_shutdown(); 2795 eina_shutdown();
2796} 2796}
2797END_TEST 2797EFL_END_TEST
2798 2798
2799START_TEST(eina_value_test_optional_int) 2799EFL_START_TEST(eina_value_test_optional_int)
2800{ 2800{
2801 eina_init(); 2801 eina_init();
2802 2802
@@ -2834,9 +2834,9 @@ START_TEST(eina_value_test_optional_int)
2834 /* eina_value_free(value); */ 2834 /* eina_value_free(value); */
2835 eina_shutdown(); 2835 eina_shutdown();
2836} 2836}
2837END_TEST 2837EFL_END_TEST
2838 2838
2839START_TEST(eina_value_test_optional_string) 2839EFL_START_TEST(eina_value_test_optional_string)
2840{ 2840{
2841 eina_init(); 2841 eina_init();
2842 2842
@@ -2875,9 +2875,9 @@ START_TEST(eina_value_test_optional_string)
2875 eina_value_free(value); 2875 eina_value_free(value);
2876 eina_shutdown(); 2876 eina_shutdown();
2877} 2877}
2878END_TEST 2878EFL_END_TEST
2879 2879
2880START_TEST(eina_value_test_optional_struct_members) 2880EFL_START_TEST(eina_value_test_optional_struct_members)
2881{ 2881{
2882 eina_init(); 2882 eina_init();
2883 2883
@@ -2935,9 +2935,9 @@ START_TEST(eina_value_test_optional_struct_members)
2935 2935
2936 eina_shutdown(); 2936 eina_shutdown();
2937} 2937}
2938END_TEST 2938EFL_END_TEST
2939 2939
2940START_TEST(eina_value_test_value) 2940EFL_START_TEST(eina_value_test_value)
2941{ 2941{
2942 Eina_Value composed, v; 2942 Eina_Value composed, v;
2943 const int ivalue = 3500; 2943 const int ivalue = 3500;
@@ -2969,9 +2969,9 @@ START_TEST(eina_value_test_value)
2969 eina_value_flush(&composed); 2969 eina_value_flush(&composed);
2970 eina_shutdown(); 2970 eina_shutdown();
2971} 2971}
2972END_TEST 2972EFL_END_TEST
2973 2973
2974START_TEST(eina_value_test_value_string) 2974EFL_START_TEST(eina_value_test_value_string)
2975{ 2975{
2976 Eina_Value composed, v, str_v; 2976 Eina_Value composed, v, str_v;
2977 const char *msg = "A string", *str; 2977 const char *msg = "A string", *str;
@@ -3002,7 +3002,7 @@ START_TEST(eina_value_test_value_string)
3002 eina_value_flush(&v); 3002 eina_value_flush(&v);
3003 eina_shutdown(); 3003 eina_shutdown();
3004} 3004}
3005END_TEST 3005EFL_END_TEST
3006 3006
3007void 3007void
3008eina_test_value(TCase *tc) 3008eina_test_value(TCase *tc)