Add g_assert_cmpstrv() test utility
I have several projects which return GStrv
(aka char **
) values, have boxed properties of that type (for example, combined with json-glib). In my unit tests, I now have to write the following:
GStrv actual, expected;
g_assert_cmpuint (g_strv_length (actual), g_strv_length (expected));
g_assert_true (g_strv_equal (actual, expected));
This doesn't gave a lot of info however if it fails for either assertions. Ideally, it would be nice to print out both string arrays, so we can visually compare what's wrong. My proposal is to write an addional macro in gtestutils.h
that adds this functionality.