diff options
author | Carlos Garcia Campos <cgarcia@igalia.com> | 2018-06-13 17:09:13 +0200 |
---|---|---|
committer | Carlos Garcia Campos <carlosgc@gnome.org> | 2018-06-28 14:58:24 +0200 |
commit | afde25508d099b4283524fbf9ecde3a7d5abbeff (patch) | |
tree | a0a2120495668f6964f6af1d2a299dcfc8c7fd0c /tests | |
parent | 26a2ca50eec9b1d774bf49cbd52a95941401e602 (diff) | |
download | epiphany-afde25508d099b4283524fbf9ecde3a7d5abbeff.tar.gz |
Enable web app utils tests again
Add a new file helpers flag to indicate it's a private profile for
testing. In testing mode, we should never use the user dot dir, so this
private profile dir should be considered the default one.
https://bugzilla.gnome.org/show_bug.cgi?id=759256
Diffstat (limited to 'tests')
-rw-r--r-- | tests/ephy-web-app-utils-test.c | 6 | ||||
-rw-r--r-- | tests/meson.build | 17 |
2 files changed, 11 insertions, 12 deletions
diff --git a/tests/ephy-web-app-utils-test.c b/tests/ephy-web-app-utils-test.c index 8a4b7bab3..8d80ab665 100644 --- a/tests/ephy-web-app-utils-test.c +++ b/tests/ephy-web-app-utils-test.c @@ -65,7 +65,7 @@ test_web_app_lifetime (void) g_test_message ("NAME: %s", test.name); /* Test creation */ - desktop_file = ephy_web_application_create (test.url, test.name, NULL); + desktop_file = ephy_web_application_create (test.name, test.url, NULL); g_assert (g_str_has_prefix (desktop_file, ephy_dot_dir ())); g_assert (g_file_test (desktop_file, G_FILE_TEST_EXISTS)); @@ -91,7 +91,7 @@ test_web_app_lifetime (void) g_assert_cmpstr (app->name, ==, test.name); g_assert_cmpstr (app->url, ==, test.url); g_assert_cmpstr (app->desktop_file, ==, basename); - g_assert (g_str_has_prefix (app->icon_url, profile_dir)); + g_assert_null (app->icon_url); ephy_web_application_free_application_list (apps); @@ -120,7 +120,7 @@ main (int argc, char *argv[]) { int ret; - if (!ephy_file_helpers_init (NULL, EPHY_FILE_HELPERS_PRIVATE_PROFILE | EPHY_FILE_HELPERS_ENSURE_EXISTS, NULL)) { + if (!ephy_file_helpers_init (NULL, EPHY_FILE_HELPERS_TESTING_MODE | EPHY_FILE_HELPERS_ENSURE_EXISTS, NULL)) { g_debug ("Something wrong happened with ephy_file_helpers_init()"); return -1; } diff --git a/tests/meson.build b/tests/meson.build index 89f903ac3..e03d4ea82 100644 --- a/tests/meson.build +++ b/tests/meson.build @@ -169,15 +169,14 @@ if get_option('unit_tests') env: envs, ) - # FIXME: https://bugzilla.gnome.org/show_bug.cgi?id=759256 - # web_app_utils_test = executable('test-ephy-web-app-utils', - # 'ephy-web-app-utils-test.c', - # dependencies: ephymain_dep - # ) - # test('Web app utils test', - # web_app_utils_test, - # env: envs - # ) + web_app_utils_test = executable('test-ephy-web-app-utils', + 'ephy-web-app-utils-test.c', + dependencies: ephymain_dep + ) + test('Web app utils test', + web_app_utils_test, + env: envs + ) # FIXME: https://bugzilla.gnome.org/show_bug.cgi?id=780280 # web_view_test = executable('test-ephy-web-view', |