--- a/gplugin/tests/test-plugin-info.c Tue Jan 22 23:18:33 2019 -0600
+++ b/gplugin/tests/test-plugin-info.c Sun Jan 27 00:33:19 2019 -0600
@@ -42,18 +42,26 @@
test_stringv(gchar **got, const gchar * const * const expected,
TestStringVFunc func, GPluginPluginInfo *info)
- for(i = 0; expected[i]; i++)
- g_assert_cmpstr(got[i], ==, expected[i]);
+ /* make sure our arrarys are the same length */ + g_assert_cmpuint(g_strv_length(got), ==, g_strv_length(expected)); + /* now walk through until expected[i] is null comparing each entry */ + for(i = 0; expected[i]; i++) + g_assert_cmpstr(got[i], ==, expected[i]);
+ /* call the accessor on the GPluginPluginInfo object */ - for(i = 0; got[i]; i++)
- g_assert_cmpstr(got[i], ==, tmp[i]);
+ /* verify that the accessor returned the proper value as well */ + g_assert_cmpuint(g_strv_length(tmp), ==, g_strv_length(expected));
+ for(i = 0; expected[i]; i++) + g_assert_cmpstr(tmp[i], ==, expected[i]); /******************************************************************************