Merge lp:~phablet-team/messaging-framework/self-id into lp:messaging-framework

Proposed by Roberto Mier Escandon
Status: Merged
Approved by: Tiago Salem Herrmann
Approved revision: 69
Merged at revision: 67
Proposed branch: lp:~phablet-team/messaging-framework/self-id
Merge into: lp:messaging-framework
Prerequisite: lp:~phablet-team/messaging-framework/enable_message_broadcast
Diff against target: 68 lines (+16/-1)
5 files modified
debian/changelog (+6/-0)
include/messaging/connection.h (+3/-0)
src/messaging/qt/tp/connection.cpp (+1/-1)
tests/mock_connection.h (+1/-0)
tests/unit/messaging/connection_test.cpp (+5/-0)
To merge this branch: bzr merge lp:~phablet-team/messaging-framework/self-id
Reviewer Review Type Date Requested Status
Tiago Salem Herrmann (community) Approve
system-apps-ci-bot continuous-integration Approve
Review via email: mp+307701@code.launchpad.net

Commit message

Added self identifier

NOTE: This branch should be landed along with https://code.launchpad.net/~ningbo-team/ningbo/self-id/+merge/307702

Description of the change

Added self identifier

NOTE: This branch should be landed along with https://code.launchpad.net/~ningbo-team/ningbo/self-id/+merge/307702

To post a comment you must log in.
Revision history for this message
system-apps-ci-bot (system-apps-ci-bot) wrote :

PASSED: Continuous integration, rev:69
https://jenkins.canonical.com/system-apps/job/lp-messaging-framework-ci/86/
Executed test runs:
    SUCCESS: https://jenkins.canonical.com/system-apps/job/build/1752
    SUCCESS: https://jenkins.canonical.com/system-apps/job/test-0-autopkgtest/label=phone-armhf,release=vivid+overlay,testname=default/426
    SUCCESS: https://jenkins.canonical.com/system-apps/job/build-0-fetch/1752
    SUCCESS: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=amd64,release=vivid+overlay/1597
        deb: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=amd64,release=vivid+overlay/1597/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=amd64,release=xenial+overlay/1597
        deb: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=amd64,release=xenial+overlay/1597/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=amd64,release=yakkety/1597
        deb: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=amd64,release=yakkety/1597/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=armhf,release=vivid+overlay/1597
        deb: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=armhf,release=vivid+overlay/1597/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=armhf,release=xenial+overlay/1597
        deb: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=armhf,release=xenial+overlay/1597/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=armhf,release=yakkety/1597
        deb: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=armhf,release=yakkety/1597/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=i386,release=vivid+overlay/1597
        deb: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=i386,release=vivid+overlay/1597/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=i386,release=xenial+overlay/1597
        deb: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=i386,release=xenial+overlay/1597/artifact/output/*zip*/output.zip
    SUCCESS: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=i386,release=yakkety/1597
        deb: https://jenkins.canonical.com/system-apps/job/build-2-binpkg/arch=i386,release=yakkety/1597/artifact/output/*zip*/output.zip

Click here to trigger a rebuild:
https://jenkins.canonical.com/system-apps/job/lp-messaging-framework-ci/86/rebuild

review: Approve (continuous-integration)
Revision history for this message
Tiago Salem Herrmann (tiagosh) wrote :

thanks.
We are using this info in messaging-app now to display the "me" participant.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'debian/changelog'
--- debian/changelog 2016-10-05 11:58:12 +0000
+++ debian/changelog 2016-10-05 11:58:12 +0000
@@ -1,3 +1,9 @@
1messaging-framework (0.1+16.10.20161005-1ubuntu28) vivid; urgency=medium
2
3 * Self identifier support
4
5 -- Roberto Mier Escandon <roberto.escandon@canonical.com> Wed, 05 Oct 2016 13:38:22 +0200
6
1messaging-framework (0.1+16.10.20160926-1ubuntu28) vivid; urgency=medium7messaging-framework (0.1+16.10.20160926-1ubuntu28) vivid; urgency=medium
28
3 * Bugfix: The participant who was invited back is shown as admin9 * Bugfix: The participant who was invited back is shown as admin
410
=== modified file 'include/messaging/connection.h'
--- include/messaging/connection.h 2016-05-17 19:33:22 +0000
+++ include/messaging/connection.h 2016-10-05 11:58:12 +0000
@@ -77,6 +77,9 @@
77 77
78 };78 };
7979
80 /// @brief self_identifier returns the current registered user identifier
81 virtual std::string self_identifier() = 0;
82
80 /// @brief presence_manager returns a shared pointer to a PresenceManager object83 /// @brief presence_manager returns a shared pointer to a PresenceManager object
81 virtual std::shared_ptr<PresenceManager> presence_manager() = 0;84 virtual std::shared_ptr<PresenceManager> presence_manager() = 0;
8285
8386
=== modified file 'src/messaging/qt/tp/connection.cpp'
--- src/messaging/qt/tp/connection.cpp 2016-10-05 11:58:12 +0000
+++ src/messaging/qt/tp/connection.cpp 2016-10-05 11:58:12 +0000
@@ -155,7 +155,7 @@
155 qRegisterMetaType<messaging::Recipient::shared_ptr>();155 qRegisterMetaType<messaging::Recipient::shared_ptr>();
156156
157 setSelfHandle(1);157 setSelfHandle(1);
158 handles_.insert(HandleIdPair(1, "my_myself_and_i"));158 handles_.insert(HandleIdPair(1, QString::fromStdString(connection->self_identifier())));
159159
160 // Wire up the actual request for connecting.160 // Wire up the actual request for connecting.
161 setConnectCallback(Tp::memFun(this, &tp::Connection::connect));161 setConnectCallback(Tp::memFun(this, &tp::Connection::connect));
162162
=== modified file 'tests/mock_connection.h'
--- tests/mock_connection.h 2016-06-07 18:15:24 +0000
+++ tests/mock_connection.h 2016-10-05 11:58:12 +0000
@@ -45,6 +45,7 @@
4545
46 void announce_status_connected();46 void announce_status_connected();
4747
48 MOCK_METHOD0(self_identifier, std::string());
48 MOCK_METHOD0(presence_manager, std::shared_ptr<messaging::PresenceManager>());49 MOCK_METHOD0(presence_manager, std::shared_ptr<messaging::PresenceManager>());
49 MOCK_METHOD0(messenger, std::shared_ptr<messaging::Messenger>());50 MOCK_METHOD0(messenger, std::shared_ptr<messaging::Messenger>());
50 MOCK_METHOD0(group_starter, std::shared_ptr<messaging::GroupStarter>());51 MOCK_METHOD0(group_starter, std::shared_ptr<messaging::GroupStarter>());
5152
=== modified file 'tests/unit/messaging/connection_test.cpp'
--- tests/unit/messaging/connection_test.cpp 2016-05-19 11:56:55 +0000
+++ tests/unit/messaging/connection_test.cpp 2016-10-05 11:58:12 +0000
@@ -30,6 +30,11 @@
30 {30 {
31 }31 }
3232
33 std::string self_identifier() override
34 {
35 throw std::logic_error{"Not implemented"};
36 }
37
33 std::shared_ptr<messaging::PresenceManager> presence_manager() override38 std::shared_ptr<messaging::PresenceManager> presence_manager() override
34 {39 {
35 throw std::logic_error{"Not implemented"};40 throw std::logic_error{"Not implemented"};

Subscribers

People subscribed via source and target branches

to all changes: