From 8729c4b0b5f99e1ca1d4e616a06cad687a08c758 Mon Sep 17 00:00:00 2001 From: Mike Blumenkrantz Date: Tue, 26 Nov 2019 10:52:31 -0500 Subject: [PATCH] tests/layout: fix theme apply test for layout object the group previously used (efl/win/background) no longer exists, and this test never verified that the theme_set call succeeded so this has been failing silently for a long time now we check and verify that the call succeeds in addition to using a valid group Reviewed-by: Marcel Hollerbach Differential Revision: https://phab.enlightenment.org/D10739 --- src/tests/elementary/efl_ui_test_layout.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/tests/elementary/efl_ui_test_layout.c b/src/tests/elementary/efl_ui_test_layout.c index 5aa64e0688..6a1763f620 100644 --- a/src/tests/elementary/efl_ui_test_layout.c +++ b/src/tests/elementary/efl_ui_test_layout.c @@ -153,15 +153,17 @@ EFL_START_TEST(efl_ui_layout_test_layout_theme) { Evas_Object *win; const char *klass, *group, *style; + Eina_Error err; win = win_add(NULL, "layout", EFL_UI_WIN_TYPE_BASIC); Eo *layout = efl_add(EFL_UI_LAYOUT_CLASS, win, - efl_ui_layout_theme_set(efl_added, "win", "background", NULL) + err = efl_ui_layout_theme_set(efl_added, "button", NULL, "anchor") ); + ck_assert_int_eq(err, 0); efl_ui_layout_theme_get(layout, &klass, &group, &style); - ck_assert_str_eq(klass, "win"); - ck_assert_str_eq(group, "background"); - ck_assert(!style); + ck_assert_str_eq(klass, "button"); + ck_assert(!group); + ck_assert_str_eq(style, "anchor"); } EFL_END_TEST