[tepl] amtk: testsuite: test-action-info-store
- From: Sébastien Wilmet <swilmet src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tepl] amtk: testsuite: test-action-info-store
- Date: Fri, 14 Jul 2017 14:01:49 +0000 (UTC)
commit 67f4057b321c83d0c5b8729223d03554e743585b
Author: Sébastien Wilmet <swilmet gnome org>
Date: Thu Jul 13 16:41:26 2017 +0200
amtk: testsuite: test-action-info-store
testsuite/Makefile.am | 4 +-
testsuite/{ => amtk}/test-action-info-store.c | 37 +++++++++++++------------
2 files changed, 21 insertions(+), 20 deletions(-)
---
diff --git a/testsuite/Makefile.am b/testsuite/Makefile.am
index 46f9325..497fda6 100644
--- a/testsuite/Makefile.am
+++ b/testsuite/Makefile.am
@@ -28,8 +28,8 @@ UNIT_TEST_PROGS =
UNIT_TEST_PROGS += amtk-test-utils
amtk_test_utils_SOURCES = amtk/test-utils.c
-UNIT_TEST_PROGS += test-action-info-store
-test_action_info_store_SOURCES = test-action-info-store.c
+UNIT_TEST_PROGS += amtk-test-action-info-store
+amtk_test_action_info_store_SOURCES = amtk/test-action-info-store.c
UNIT_TEST_PROGS += test-action-map
test_action_map_SOURCES = test-action-map.c
diff --git a/testsuite/test-action-info-store.c b/testsuite/amtk/test-action-info-store.c
similarity index 58%
rename from testsuite/test-action-info-store.c
rename to testsuite/amtk/test-action-info-store.c
index 1a6d55f..98ad5d7 100644
--- a/testsuite/test-action-info-store.c
+++ b/testsuite/amtk/test-action-info-store.c
@@ -1,14 +1,14 @@
/*
- * This file is part of Tepl, a text editor library.
+ * This file is part of Amtk - Actions, Menus and Toolbars Kit
*
* Copyright 2017 - Sébastien Wilmet <swilmet gnome org>
*
- * Tepl is free software; you can redistribute it and/or modify it under
+ * Amtk is free software; you can redistribute it and/or modify it under
* the terms of the GNU Lesser General Public License as published by the
* Free Software Foundation; either version 2.1 of the License, or (at your
* option) any later version.
*
- * Tepl is distributed in the hope that it will be useful, but WITHOUT ANY
+ * Amtk is distributed in the hope that it will be useful, but WITHOUT ANY
* WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
@@ -17,17 +17,17 @@
* along with this library; if not, see <http://www.gnu.org/licenses/>.
*/
-#include <tepl/tepl.h>
+#include <amtk/amtk.h>
static void
test_add_entries (void)
{
- TeplActionInfoStore *store;
- TeplActionInfoCentralStore *central_store;
- const TeplActionInfo *info1;
- const TeplActionInfo *info2;
+ AmtkActionInfoStore *store;
+ AmtkActionInfoCentralStore *central_store;
+ const AmtkActionInfo *info1;
+ const AmtkActionInfo *info2;
- const TeplActionInfoEntry entries[] =
+ const AmtkActionInfoEntry entries[] =
{
/* action, icon, label, accel, tooltip */
@@ -38,30 +38,31 @@ test_add_entries (void)
{ "win.open", "document-open", "_Open", "<Control>o" },
};
- store = tepl_action_info_store_new (NULL);
+ store = amtk_action_info_store_new (NULL);
- tepl_action_info_store_add_entries (store,
+ amtk_action_info_store_add_entries (store,
entries,
G_N_ELEMENTS (entries),
NULL);
- info1 = tepl_action_info_store_lookup (store, "win.open");
+ info1 = amtk_action_info_store_lookup (store, "win.open");
g_assert (info1 != NULL);
- g_assert_cmpstr (tepl_action_info_get_icon_name (info1), ==, "document-open");
- g_assert (tepl_action_info_get_tooltip (info1) == NULL);
+ g_assert_cmpstr (amtk_action_info_get_icon_name (info1), ==, "document-open");
+ g_assert (amtk_action_info_get_tooltip (info1) == NULL);
- central_store = tepl_action_info_central_store_get_instance ();
- info2 = tepl_action_info_central_store_lookup (central_store, "win.open");
+ central_store = amtk_action_info_central_store_get_instance ();
+ info2 = amtk_action_info_central_store_lookup (central_store, "win.open");
g_assert (info1 == info2);
- info1 = tepl_action_info_store_lookup (store, "plouf");
+ info1 = amtk_action_info_store_lookup (store, "plouf");
g_assert (info1 == NULL);
g_object_unref (store);
}
int
-main (int argc, char **argv)
+main (int argc,
+ char **argv)
{
gtk_test_init (&argc, &argv);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]