mirror of
https://github.com/profanity-im/profanity.git
synced 2024-09-01 19:24:15 -04:00
Add connection_get_profanity_identifier stub
And move defintion to xmpp.h
This commit is contained in:
parent
33083662d1
commit
5c6f5ba0f7
@ -49,7 +49,7 @@
|
||||
#include "event/common.h"
|
||||
#include "plugins/plugins.h"
|
||||
#include "ui/window_list.h"
|
||||
#include "xmpp/connection.h"
|
||||
#include "xmpp/xmpp.h"
|
||||
#include "xmpp/muc.h"
|
||||
#include "xmpp/chat_session.h"
|
||||
#include "xmpp/roster_list.h"
|
||||
|
@ -64,6 +64,4 @@ void connection_remove_available_resource(const char *const resource);
|
||||
|
||||
char* connection_create_stanza_id(void);
|
||||
|
||||
char *connection_get_profanity_identifier(void);
|
||||
|
||||
#endif
|
||||
|
@ -140,6 +140,8 @@ GList* connection_get_available_resources(void);
|
||||
gboolean connection_supports(const char *const feature);
|
||||
char* connection_jid_for_feature(const char *const feature);
|
||||
|
||||
char *connection_get_profanity_identifier(void);
|
||||
|
||||
char* message_send_chat(const char *const barejid, const char *const msg, const char *const oob_url,
|
||||
gboolean request_receipt);
|
||||
char* message_send_chat_otr(const char *const barejid, const char *const msg, gboolean request_receipt);
|
||||
|
@ -7,6 +7,7 @@
|
||||
#include <glib.h>
|
||||
|
||||
#include "event/server_events.h"
|
||||
#include "xmpp/xmpp.h"
|
||||
#include "xmpp/roster_list.h"
|
||||
#include "xmpp/chat_session.h"
|
||||
#include "config/preferences.h"
|
||||
|
7
tests/unittests/xmpp/stub_connection.c
Normal file
7
tests/unittests/xmpp/stub_connection.c
Normal file
@ -0,0 +1,7 @@
|
||||
#include "xmpp/message.h"
|
||||
|
||||
ProfMessage *message_init(void) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void message_free(ProfMessage *message) {}
|
@ -92,6 +92,10 @@ connection_supports(const char *const feature)
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
char *connection_get_profanity_identifier(void) {
|
||||
return "profident";
|
||||
}
|
||||
|
||||
// message functions
|
||||
char* message_send_chat(const char * const barejid, const char * const msg, const char *const oob_url,
|
||||
gboolean request_receipt)
|
||||
|
Loading…
Reference in New Issue
Block a user