summaryrefslogtreecommitdiff
path: root/src/tests
diff options
context:
space:
mode:
authorAndy Williams <andy@andywilliams.me>2018-03-28 16:44:40 +0100
committerAndy Williams <andy@andywilliams.me>2018-03-28 17:30:17 +0100
commitcc2b7a10a8236e2b3cc4a25b4b4fda95e00884fc (patch)
treefe9dbfbb5f2465e57ffe5475dcbfafd619f68180 /src/tests
parent3b60da0e37c00a34a949b7354bcd333414c01c0b (diff)
downloadefl-cc2b7a10a8236e2b3cc4a25b4b4fda95e00884fc.tar.gz
elm_code: Remove a render test and complex workarounds required
Fixes issues with Windows and general unused method warnings
Diffstat (limited to 'src/tests')
-rw-r--r--src/tests/elementary/elm_code_test_widget.c54
1 files changed, 0 insertions, 54 deletions
diff --git a/src/tests/elementary/elm_code_test_widget.c b/src/tests/elementary/elm_code_test_widget.c
index 193f1f1f7d..41eba56205 100644
--- a/src/tests/elementary/elm_code_test_widget.c
+++ b/src/tests/elementary/elm_code_test_widget.c
@@ -24,59 +24,6 @@
#undef DBG
#define DBG(...) do { } while (0);
-// Guard against multiple redefinitions on Windows
-#define ELM_CODE_TEST
-
-#include "elm_code_parse.c"
-#include "elm_code_widget_selection.c"
-#include "elm_code_widget.c"
-
-#undef ELM_CODE_TEST
-
-static void _assert_cell_type(Evas_Textgrid_Cell cell, Elm_Code_Token_Type type, int id)
-{
- ck_assert_msg(cell.fg == type, "Wrong type for cell %d", id);
-}
-
-START_TEST (elm_code_widget_token_render_simple_test)
-{
- Elm_Code_File *file;
- Elm_Code_Line *line;
- Elm_Code *code;
- Elm_Code_Widget *widget;
- Evas_Object *win;
-
- int length;
- unsigned int gutter;
-
- Evas_Textgrid_Cell cells[25];
-
- char *args[] = { "exe" };
- elm_init(1, args);
- code = elm_code_create();
-
- win = elm_win_add(NULL, "code", ELM_WIN_BASIC);
- widget = elm_code_widget_add(win, code);
-
- file = code->file;
- elm_code_file_line_append(file, "some \"test content\", 45", 23, NULL);
- line = elm_code_file_line_get(file, 1);
- length = line->length;
-
- elm_code_line_token_add(line, 5, 18, 1, ELM_CODE_TOKEN_TYPE_COMMENT);
- elm_code_line_token_add(line, 21, 22, 1, ELM_CODE_TOKEN_TYPE_NUMBER);
-
- _elm_code_widget_fill_line_tokens(widget, cells, length+1, line);
- gutter = elm_obj_code_widget_text_left_gutter_width_get(widget);
-
- _assert_cell_type(cells[gutter+15], ELM_CODE_TOKEN_TYPE_COMMENT, 16);
- _assert_cell_type(cells[gutter+21], ELM_CODE_TOKEN_TYPE_NUMBER, 22);
-
- elm_code_free(code);
- elm_shutdown();
-}
-END_TEST
-
START_TEST (elm_code_widget_construct)
{
Elm_Code *code;
@@ -150,7 +97,6 @@ END_TEST
void elm_code_test_widget(TCase *tc)
{
- tcase_add_test(tc, elm_code_widget_token_render_simple_test);
tcase_add_test(tc, elm_code_widget_construct);
tcase_add_test(tc, elm_code_widget_construct_nocode);
tcase_add_test(tc, elm_code_widget_position);