summaryrefslogtreecommitdiff
path: root/src/tests/elementary/elm_code_file_test_load.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/elementary/elm_code_file_test_load.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/elementary/elm_code_file_test_load.c')
-rw-r--r--src/tests/elementary/elm_code_file_test_load.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/tests/elementary/elm_code_file_test_load.c b/src/tests/elementary/elm_code_file_test_load.c
index a17548f..4a2aced 100644
--- a/src/tests/elementary/elm_code_file_test_load.c
+++ b/src/tests/elementary/elm_code_file_test_load.c
@@ -9,7 +9,7 @@
9#include "elm_suite.h" 9#include "elm_suite.h"
10#include "Elementary.h" 10#include "Elementary.h"
11 11
12START_TEST (elm_code_file_load) 12EFL_START_TEST (elm_code_file_load)
13{ 13{
14 char *path = TESTS_SRC_DIR "/testfile.txt"; 14 char *path = TESTS_SRC_DIR "/testfile.txt";
15 char real[EINA_PATH_MAX]; 15 char real[EINA_PATH_MAX];
@@ -28,9 +28,9 @@ START_TEST (elm_code_file_load)
28 elm_code_free(code); 28 elm_code_free(code);
29 elm_shutdown(); 29 elm_shutdown();
30} 30}
31END_TEST 31EFL_END_TEST
32 32
33START_TEST (elm_code_file_load_lines) 33EFL_START_TEST (elm_code_file_load_lines)
34{ 34{
35 char *path = TESTS_SRC_DIR "/testfile.txt"; 35 char *path = TESTS_SRC_DIR "/testfile.txt";
36 Elm_Code_File *file; 36 Elm_Code_File *file;
@@ -46,9 +46,9 @@ START_TEST (elm_code_file_load_lines)
46 elm_code_free(code); 46 elm_code_free(code);
47 elm_shutdown(); 47 elm_shutdown();
48} 48}
49END_TEST 49EFL_END_TEST
50 50
51START_TEST (elm_code_file_load_blank_lines) 51EFL_START_TEST (elm_code_file_load_blank_lines)
52{ 52{
53 char *path = TESTS_SRC_DIR "/testfile-withblanks.txt"; 53 char *path = TESTS_SRC_DIR "/testfile-withblanks.txt";
54 Elm_Code_File *file; 54 Elm_Code_File *file;
@@ -64,9 +64,9 @@ START_TEST (elm_code_file_load_blank_lines)
64 elm_code_free(code); 64 elm_code_free(code);
65 elm_shutdown(); 65 elm_shutdown();
66} 66}
67END_TEST 67EFL_END_TEST
68 68
69START_TEST (elm_code_file_load_windows) 69EFL_START_TEST (elm_code_file_load_windows)
70{ 70{
71 char *path = TESTS_SRC_DIR "/testfile-windows.txt"; 71 char *path = TESTS_SRC_DIR "/testfile-windows.txt";
72 Elm_Code_File *file; 72 Elm_Code_File *file;
@@ -82,7 +82,7 @@ START_TEST (elm_code_file_load_windows)
82 elm_code_free(code); 82 elm_code_free(code);
83 elm_shutdown(); 83 elm_shutdown();
84} 84}
85END_TEST 85EFL_END_TEST
86 86
87static void _assert_line_content_eq(const char *content, Elm_Code_Line *line) 87static void _assert_line_content_eq(const char *content, Elm_Code_Line *line)
88{ 88{
@@ -96,7 +96,7 @@ static void _assert_line_content_eq(const char *content, Elm_Code_Line *line)
96 ck_assert_uint_eq(content[c], line->content[c]); 96 ck_assert_uint_eq(content[c], line->content[c]);
97} 97}
98 98
99START_TEST (elm_code_file_load_content) 99EFL_START_TEST (elm_code_file_load_content)
100{ 100{
101 char *path = TESTS_SRC_DIR "/testfile.txt"; 101 char *path = TESTS_SRC_DIR "/testfile.txt";
102 Elm_Code_File *file; 102 Elm_Code_File *file;
@@ -113,9 +113,9 @@ START_TEST (elm_code_file_load_content)
113 elm_code_free(code); 113 elm_code_free(code);
114 elm_shutdown(); 114 elm_shutdown();
115} 115}
116END_TEST 116EFL_END_TEST
117 117
118START_TEST (elm_code_file_line_ending_unix) 118EFL_START_TEST (elm_code_file_line_ending_unix)
119{ 119{
120 char *path = TESTS_SRC_DIR "/testfile.txt"; 120 char *path = TESTS_SRC_DIR "/testfile.txt";
121 Elm_Code_File *file; 121 Elm_Code_File *file;
@@ -135,9 +135,9 @@ START_TEST (elm_code_file_line_ending_unix)
135 elm_code_free(code); 135 elm_code_free(code);
136 elm_shutdown(); 136 elm_shutdown();
137} 137}
138END_TEST 138EFL_END_TEST
139 139
140START_TEST (elm_code_file_line_ending_windows) 140EFL_START_TEST (elm_code_file_line_ending_windows)
141{ 141{
142 char *path = TESTS_SRC_DIR "/testfile-windows.txt"; 142 char *path = TESTS_SRC_DIR "/testfile-windows.txt";
143 Elm_Code_File *file; 143 Elm_Code_File *file;
@@ -157,7 +157,7 @@ START_TEST (elm_code_file_line_ending_windows)
157 elm_code_free(code); 157 elm_code_free(code);
158 elm_shutdown(); 158 elm_shutdown();
159} 159}
160END_TEST 160EFL_END_TEST
161 161
162void elm_code_file_test_load(TCase *tc) 162void elm_code_file_test_load(TCase *tc)
163{ 163{