summaryrefslogtreecommitdiff
path: root/src/tests/elementary/elm_code_test_text.c
diff options
context:
space:
mode:
authorAndy Williams <andy@andywilliams.me>2016-11-28 01:01:35 +0000
committerAndy Williams <andy@andywilliams.me>2016-11-28 01:01:35 +0000
commit60cd21979228482a6245f03d8110aafa2810f5d6 (patch)
tree16bc1b379e225fe111cc3842ec19316d47e292e8 /src/tests/elementary/elm_code_test_text.c
parentc5181470c169874026bd7836dc2aa48c5b0d75e7 (diff)
tests: Update for elm_code indent changes
Diffstat (limited to 'src/tests/elementary/elm_code_test_text.c')
-rw-r--r--src/tests/elementary/elm_code_test_text.c42
1 files changed, 0 insertions, 42 deletions
diff --git a/src/tests/elementary/elm_code_test_text.c b/src/tests/elementary/elm_code_test_text.c
index fb198c9..dfff80f 100644
--- a/src/tests/elementary/elm_code_test_text.c
+++ b/src/tests/elementary/elm_code_test_text.c
@@ -115,46 +115,6 @@ START_TEST (elm_code_text_newline_position_test)
115} 115}
116END_TEST 116END_TEST
117 117
118START_TEST (elm_code_text_leading_whitespace_test)
119{
120 const char *text;
121
122 elm_init(1, NULL);
123 text = "testing";
124 ck_assert_int_eq(0, elm_code_text_leading_whitespace_length(text, strlen(text)));
125
126 text = " spaces";
127 ck_assert_int_eq(2, elm_code_text_leading_whitespace_length(text, strlen(text)));
128
129 text = "\t\ttabs";
130 ck_assert_int_eq(2, elm_code_text_leading_whitespace_length(text, strlen(text)));
131
132 text = " \t mix";
133 ck_assert_int_eq(3, elm_code_text_leading_whitespace_length(text, strlen(text)));
134 elm_shutdown();
135}
136END_TEST
137
138START_TEST (elm_code_text_trailing_whitespace_test)
139{
140 const char *text;
141
142 elm_init(1, NULL);
143 text = "testing";
144 ck_assert_int_eq(0, elm_code_text_trailing_whitespace_length(text, strlen(text)));
145
146 text = "spaces ";
147 ck_assert_int_eq(2, elm_code_text_trailing_whitespace_length(text, strlen(text)));
148
149 text = "tabs\t\t";
150 ck_assert_int_eq(2, elm_code_text_trailing_whitespace_length(text, strlen(text)));
151
152 text = "mix \t ";
153 ck_assert_int_eq(3, elm_code_text_trailing_whitespace_length(text, strlen(text)));
154 elm_shutdown();
155}
156END_TEST
157
158START_TEST (elm_code_text_is_whitespace_test) 118START_TEST (elm_code_text_is_whitespace_test)
159{ 119{
160 const char *text; 120 const char *text;
@@ -179,7 +139,5 @@ void elm_code_test_text(TCase *tc)
179 tcase_add_test(tc, elm_code_text_contains_test); 139 tcase_add_test(tc, elm_code_text_contains_test);
180 tcase_add_test(tc, elm_code_text_strpos_test); 140 tcase_add_test(tc, elm_code_text_strpos_test);
181 tcase_add_test(tc, elm_code_text_newline_position_test); 141 tcase_add_test(tc, elm_code_text_newline_position_test);
182 tcase_add_test(tc, elm_code_text_leading_whitespace_test);
183 tcase_add_test(tc, elm_code_text_trailing_whitespace_test);
184 tcase_add_test(tc, elm_code_text_is_whitespace_test); 142 tcase_add_test(tc, elm_code_text_is_whitespace_test);
185} 143}