summaryrefslogtreecommitdiff
path: root/src/tests/eeze
diff options
context:
space:
mode:
authorGustavo Sverzut Barbieri <barbieri@gmail.com>2013-01-17 20:31:06 +0000
committerGustavo Sverzut Barbieri <barbieri@gmail.com>2013-01-17 20:31:06 +0000
commit69650dd84c131d8b810c6e32b1e874e1663bf5f9 (patch)
tree790eb178ec51bec50a8d011134b1f292a5c85b8b /src/tests/eeze
parent09e5bc40ef88efa8ef95a9a5dc535a35d0117270 (diff)
eeze: remove warning and add a bit more test.
it's basically not testing anything, just calling the API :-( Added some tests that check if the listed type is of that type (mouse, touchpad, joystick). SVN revision: 82949
Diffstat (limited to 'src/tests/eeze')
-rw-r--r--src/tests/eeze/eeze_suite.c19
1 files changed, 12 insertions, 7 deletions
diff --git a/src/tests/eeze/eeze_suite.c b/src/tests/eeze/eeze_suite.c
index 191f30b668..3e30d1dba6 100644
--- a/src/tests/eeze/eeze_suite.c
+++ b/src/tests/eeze/eeze_suite.c
@@ -102,7 +102,8 @@ END_TEST
102START_TEST(eeze_test_udev_syspath) 102START_TEST(eeze_test_udev_syspath)
103{ 103{
104 Eina_List *type, *l; 104 Eina_List *type, *l;
105 const char *name, *check; 105 const char *name;
106 Eina_Bool r;
106 107
107 eeze_init(); 108 eeze_init();
108 109
@@ -110,7 +111,7 @@ START_TEST(eeze_test_udev_syspath)
110 type = eeze_udev_find_unlisted_similar(type); 111 type = eeze_udev_find_unlisted_similar(type);
111 EINA_LIST_FOREACH(type, l, name) 112 EINA_LIST_FOREACH(type, l, name)
112 { 113 {
113 check = eeze_udev_syspath_get_devpath(name); 114 eeze_udev_syspath_get_devpath(name);
114 eeze_udev_find_similar_from_syspath(name); 115 eeze_udev_find_similar_from_syspath(name);
115 eeze_udev_find_similar_from_syspath(NULL); 116 eeze_udev_find_similar_from_syspath(NULL);
116 eeze_udev_syspath_get_parent(name); 117 eeze_udev_syspath_get_parent(name);
@@ -138,23 +139,27 @@ START_TEST(eeze_test_udev_syspath)
138 type = eeze_udev_find_unlisted_similar(type); 139 type = eeze_udev_find_unlisted_similar(type);
139 EINA_LIST_FOREACH(type, l, name) 140 EINA_LIST_FOREACH(type, l, name)
140 { 141 {
141 eeze_udev_syspath_is_mouse(name); 142 r = eeze_udev_syspath_is_mouse(name);
142 eeze_udev_syspath_is_touchpad(name); 143 fail_unless(r);
143 eeze_udev_syspath_is_joystick(name); 144
145 eeze_udev_syspath_is_touchpad(name);
146 eeze_udev_syspath_is_joystick(name);
144 } 147 }
145 148
146 type = eeze_udev_find_by_type(EEZE_UDEV_TYPE_TOUCHPAD, NULL); 149 type = eeze_udev_find_by_type(EEZE_UDEV_TYPE_TOUCHPAD, NULL);
147 type = eeze_udev_find_unlisted_similar(type); 150 type = eeze_udev_find_unlisted_similar(type);
148 EINA_LIST_FOREACH(type, l, name) 151 EINA_LIST_FOREACH(type, l, name)
149 { 152 {
150 eeze_udev_syspath_is_touchpad(name); 153 r = eeze_udev_syspath_is_touchpad(name);
154 fail_unless(r);
151 } 155 }
152 156
153 type = eeze_udev_find_by_type(EEZE_UDEV_TYPE_JOYSTICK, NULL); 157 type = eeze_udev_find_by_type(EEZE_UDEV_TYPE_JOYSTICK, NULL);
154 type = eeze_udev_find_unlisted_similar(type); 158 type = eeze_udev_find_unlisted_similar(type);
155 EINA_LIST_FOREACH(type, l, name) 159 EINA_LIST_FOREACH(type, l, name)
156 { 160 {
157 eeze_udev_syspath_is_joystick(name); 161 r = eeze_udev_syspath_is_joystick(name);
162 fail_unless(r);
158 } 163 }
159 164
160 eeze_udev_devpath_get_syspath("/dev/null"); 165 eeze_udev_devpath_get_syspath("/dev/null");