diff options
author | Will Thompson <will@willthompson.co.uk> | 2012-01-30 15:41:24 +0000 |
---|---|---|
committer | Will Thompson <will@willthompson.co.uk> | 2012-01-30 15:44:12 +0000 |
commit | 10e528fb92452b21ac67a0685ed16c24ea66cba7 (patch) | |
tree | 7ca1b750105f4580862bf962887d6ab4aa0cbb48 /tests | |
parent | 2a8023ac04fdd4a3321f08c9664e63998e8689a3 (diff) |
PepService: return <item> node from get()
Diffstat (limited to 'tests')
-rw-r--r-- | tests/wocky-pep-service-test.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/tests/wocky-pep-service-test.c b/tests/wocky-pep-service-test.c index 668f6ea..d303bde 100644 --- a/tests/wocky-pep-service-test.c +++ b/tests/wocky-pep-service-test.c @@ -113,17 +113,22 @@ test_send_query_cb (GObject *source_object, { test_data_t *test = (test_data_t *) user_data; WockyStanza *reply; + WockyNode *item; WockyStanzaType type; WockyStanzaSubType sub_type; reply = wocky_pep_service_get_finish (WOCKY_PEP_SERVICE (source_object), res, - NULL); + &item, NULL); g_assert (reply != NULL); wocky_stanza_get_type_info (reply, &type, &sub_type); g_assert (type == WOCKY_STANZA_TYPE_IQ); g_assert (sub_type == WOCKY_STANZA_SUB_TYPE_RESULT); + g_assert (item != NULL); + g_assert_cmpstr (item->name, ==, "item"); + g_assert_cmpstr (wocky_node_get_attribute (item, "id"), ==, "1"); + g_object_unref (reply); test->outstanding--; @@ -169,7 +174,7 @@ test_send_query_failed_cb (GObject *source_object, GError *error = NULL; reply = wocky_pep_service_get_finish (WOCKY_PEP_SERVICE (source_object), res, - &error); + NULL, &error); g_assert (reply == NULL); g_assert_error (error, WOCKY_XMPP_CONNECTION_ERROR, WOCKY_XMPP_CONNECTION_ERROR_CLOSED); |