diff --git a/src/as-component.c b/src/as-component.c index 33749970..29ac0edf 100644 --- a/src/as-component.c +++ b/src/as-component.c @@ -3959,7 +3959,7 @@ as_component_xml_serialize_provides (AsComponent *cpt, xmlNode *cnode) (xmlChar*) g_ptr_array_index (items, j)); xmlNewProp (n, (xmlChar*) "type", - (xmlChar*) "runtime"); + (xmlChar*) "flashed"); } break; case AS_PROVIDED_KIND_DBUS_SYSTEM: diff --git a/tests/test-xmldata.c b/tests/test-xmldata.c index e9623dba..a79bb145 100644 --- a/tests/test-xmldata.c +++ b/tests/test-xmldata.c @@ -734,6 +734,8 @@ test_xml_write_provides (void) g_autoptr(AsProvided) prov_mime = NULL; g_autoptr(AsProvided) prov_bin = NULL; g_autoptr(AsProvided) prov_dbus = NULL; + g_autoptr(AsProvided) prov_firmware_runtime = NULL; + g_autoptr(AsProvided) prov_firmware_flashed = NULL; g_autofree gchar *res = NULL; const gchar *expected_prov_xml = "\n" " org.example.ProvidesTest\n" @@ -744,6 +746,8 @@ test_xml_write_provides (void) " foobar\n" " foobar-viewer\n" " org.example.ProvidesTest.Modify\n" + " ipw2200-bss.fw\n" + " 84f40464-9272-4ef7-9399-cd95f12da696\n" " \n" "\n"; @@ -768,6 +772,16 @@ test_xml_write_provides (void) as_provided_add_item (prov_dbus, "org.example.ProvidesTest.Modify"); as_component_add_provided (cpt, prov_dbus); + prov_firmware_runtime = as_provided_new (); + as_provided_set_kind (prov_firmware_runtime, AS_PROVIDED_KIND_FIRMWARE_RUNTIME); + as_provided_add_item (prov_firmware_runtime, "ipw2200-bss.fw"); + as_component_add_provided (cpt, prov_firmware_runtime); + + prov_firmware_flashed = as_provided_new (); + as_provided_set_kind (prov_firmware_flashed, AS_PROVIDED_KIND_FIRMWARE_FLASHED); + as_provided_add_item (prov_firmware_flashed, "84f40464-9272-4ef7-9399-cd95f12da696"); + as_component_add_provided (cpt, prov_firmware_flashed); + res = as_xml_test_serialize (cpt, AS_FORMAT_STYLE_METAINFO); g_assert (as_xml_test_compare_xml (res, expected_prov_xml)); }