~attente/content-hub/content-hub-glib

« back to all changes in this revision

Viewing changes to tests/acceptance-tests/app_hub_communication_default_source.cpp

  • Committer: William Hua
  • Date: 2016-11-21 21:03:30 UTC
  • mfrom: (310.1.1 content-hub-glib)
  • Revision ID: william.hua@canonical.com-20161121210330-xcrx1tqpgdv8ou53
MergeĀ lp:~ken-vandine/content-hub/content-hub-glib-dbus_test_runner

Show diffs side-by-side

added added

removed removed

Lines of Context:
106
106
        auto implementation = new cucd::Service(connection, registry, app_manager, &app);
107
107
        new ServiceAdaptor(implementation);
108
108
 
109
 
        ASSERT_TRUE(connection.registerService(service_name));
110
 
        ASSERT_TRUE(connection.registerObject("/", implementation));
 
109
        connection.registerService(service_name);
 
110
        connection.registerObject("/", implementation);
 
111
 
 
112
        QObject::connect(&app, &QCoreApplication::aboutToQuit, [&](){
 
113
            connection.unregisterObject("/");
 
114
            connection.unregisterService(service_name);
 
115
        });
111
116
 
112
117
        sync.signal_ready();
113
118
 
114
119
        app.exec();
115
 
 
116
 
        connection.unregisterObject("/");
117
 
        connection.unregisterService(service_name);
118
120
    };
119
121
 
120
122
    auto child = [&sync, default_peer_id]()