GNOME Bugzilla – Bug 657766
tests: Add tests for flat GValue arrays
Last modified: 2015-02-07 16:50:53 UTC
Just some tests for work in gjs to support flat arrays
Created attachment 195254 [details] [review] tests: Add tests for flat GValue arrays
Created attachment 195434 [details] [review] tests: Add tests for flat GValue arrays
Review of attachment 195434 [details] [review]: You're only adding one test here - So "Add input test for flat GValue array"? Do we want to support returning flat GValue arrays? If so, we should add the test now. ::: tests/gimarshallingtests.c @@ +2831,3 @@ + g_assert (g_value_get_int (&values[0]) == 42); + g_assert (g_str_equal(g_value_get_string (&values[1]), "42")); + g_assert (g_value_get_boolean (&values[2]) == TRUE); This is OK (I know the other tests use g_assert), but GTester has a nicer family of assertion functions, e.g.: g_assert_cmpstr (g_value_get_string (&values[1]), ==, "42") The value is it prints out the failing value when it's triggered so you don't have to hunt in gdb.
Created attachment 204636 [details] [review] tests: Add tests for flat GValue arrays OK.
Attachment 204636 [details] pushed as bc7b328 - tests: Add tests for flat GValue arrays
[Mass-moving gobject-introspection tickets to its own Bugzilla product - see bug 708029. Mass-filter your bugmail for this message: introspection20150207 ]