diff options
author | Marc-André Lureau <marcandre.lureau@gmail.com> | 2012-12-17 14:55:32 +0100 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2013-01-09 13:56:07 +0100 |
commit | b1efff0fdee6d986df33ec13d9d64808bf2619b6 (patch) | |
tree | e00fecce040007ba2dbbdadce7dbf7411d340d34 /tests/testdatabase.c | |
parent | 6f89276d0065a3476f9072ae5ec116633f56bdc1 (diff) | |
download | msitools-b1efff0fdee6d986df33ec13d9d64808bf2619b6.tar.gz msitools-b1efff0fdee6d986df33ec13d9d64808bf2619b6.tar.xz msitools-b1efff0fdee6d986df33ec13d9d64808bf2619b6.zip |
summary-info: replace get_property_count() by get_properties()
The later is more useful, since it returns the existing properties.
Diffstat (limited to 'tests/testdatabase.c')
-rw-r--r-- | tests/testdatabase.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/tests/testdatabase.c b/tests/testdatabase.c index 3e95f49..4a2812f 100644 --- a/tests/testdatabase.c +++ b/tests/testdatabase.c @@ -1705,11 +1705,12 @@ static unsigned add_table_to_db(LibmsiDatabase *hdb, const char *table_data) static void test_suminfo_import(void) { GError *error = NULL; + GArray *props; LibmsiDatabase *hdb; LibmsiSummaryInfo *hsi; LibmsiQuery *query = 0; const char *sql; - unsigned r, count, type; + unsigned r, type; const char *str_value; int int_value; guint64 ft_value; @@ -1734,9 +1735,9 @@ static void test_suminfo_import(void) hsi = libmsi_summary_info_new(hdb, 0, NULL); ok(hsi, "libmsi_summary_info_new() failed"); - r = libmsi_summary_info_get_property_count(hsi, &count); - ok(r == LIBMSI_RESULT_SUCCESS, "Expected LIBMSI_RESULT_SUCCESS, got %u\n", r); - ok(count == 14, "Expected 14, got %u\n", count); + props = libmsi_summary_info_get_properties (hsi); + ok(props->len == 14, "Expected 14, got %u\n", props->len); + g_array_unref (props); int_value = libmsi_summary_info_get_int (hsi, LIBMSI_PROPERTY_CODEPAGE, &error); ok(!error, "Expected success\n"); |