{"action":"created","comment":{"url":"https://api.github.com/repos/timvideos/gst-switch/pulls/comments/23828918","id":23828918,"diff_hunk":"@@ -147,6 +147,59 @@ def test_mock2(self, monkeypatch):\n         assert conn.connection is not None\n \n \n+class TestSignalSubscribe(object):\n+\n+    \"\"\"Unittests for signal_subscribe\"\"\"\n+\n+    def test_handler_not_callable(self, monkeypatch):\n+        \"\"\"Test if handler is not callable\"\"\"\n+\n+        conn = Connection()\n+        test_cbs = ['', None, [], {}]\n+        for test_cb in test_cbs:\n+            with pytest.raises(ValueError):\n+                conn.signal_subscribe(test_cb)\n+\n+    def test_handler_passed_to_gio(self, monkeypatch):\n+        \"\"\"Test if handler is correctly passed to Gio\"\"\"\n+\n+        monkeypatch.setattr(\n+            Gio.DBusConnection, 'new_for_address_sync',\n+            Mock(return_value=Gio.DBusConnection()))\n+\n+        SignalSubscribeMock = Mock()\n+        monkeypatch.setattr(\n+            Gio.DBusConnection, 'signal_subscribe',\n+            SignalSubscribeMock)\n+\n+        conn = Connection()\n+        conn.connect_dbus()\n+        test_cb = lambda: None","path":"python-api/tests/unittests/test_connection_unit.py","position":31,"original_position":31,"commit_id":"a2ecdd5a3e5b35ef262146ea7728f5c9e7bcd854","original_commit_id":"a2ecdd5a3e5b35ef262146ea7728f5c9e7bcd854","user":{"login":"MaZderMind","id":142237,"avatar_url":"https://avatars.githubusercontent.com/u/142237?v=3","gravatar_id":"","url":"https://api.github.com/users/MaZderMind","html_url":"https://github.com/MaZderMind","followers_url":"https://api.github.com/users/MaZderMind/followers","following_url":"https://api.github.com/users/MaZderMind/following{/other_user}","gists_url":"https://api.github.com/users/MaZderMind/gists{/gist_id}","starred_url":"https://api.github.com/users/MaZderMind/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MaZderMind/subscriptions","organizations_url":"https://api.github.com/users/MaZderMind/orgs","repos_url":"https://api.github.com/users/MaZderMind/repos","events_url":"https://api.github.com/users/MaZderMind/events{/privacy}","received_events_url":"https://api.github.com/users/MaZderMind/received_events","type":"User","site_admin":false},"body":"It doesn't matter because it is never called. The only thing verified here is, that the callback passed in is the same passed to Gio","created_at":"2015-01-30T08:18:18Z","updated_at":"2015-01-30T08:18:18Z","html_url":"https://github.com/timvideos/gst-switch/pull/184#discussion_r23828918","pull_request_url":"https://api.github.com/repos/timvideos/gst-switch/pulls/184","_links":{"self":{"href":"https://api.github.com/repos/timvideos/gst-switch/pulls/comments/23828918"},"html":{"href":"https://github.com/timvideos/gst-switch/pull/184#discussion_r23828918"},"pull_request":{"href":"https://api.github.com/repos/timvideos/gst-switch/pulls/184"}}},"pull_request":{"url":"https://api.github.com/repos/timvideos/gst-switch/pulls/184","id":28321738,"html_url":"https://github.com/timvideos/gst-switch/pull/184","diff_url":"https://github.com/timvideos/gst-switch/pull/184.diff","patch_url":"https://github.com/timvideos/gst-switch/pull/184.patch","issue_url":"https://api.github.com/repos/timvideos/gst-switch/issues/184","number":184,"state":"open","locked":false,"title":"Dbus API with Signals","user":{"login":"MaZderMind","id":142237,"avatar_url":"https://avatars.githubusercontent.com/u/142237?v=3","gravatar_id":"","url":"https://api.github.com/users/MaZderMind","html_url":"https://github.com/MaZderMind","followers_url":"https://api.github.com/users/MaZderMind/followers","following_url":"https://api.github.com/users/MaZderMind/following{/other_user}","gists_url":"https://api.github.com/users/MaZderMind/gists{/gist_id}","starred_url":"https://api.github.com/users/MaZderMind/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MaZderMind/subscriptions","organizations_url":"https://api.github.com/users/MaZderMind/orgs","repos_url":"https://api.github.com/users/MaZderMind/repos","events_url":"https://api.github.com/users/MaZderMind/events{/privacy}","received_events_url":"https://api.github.com/users/MaZderMind/received_events","type":"User","site_admin":false},"body":"Re-Implement the Server-to-Client-Communication using DBus-Signals.\r\nThis allows using this Communication in Python and also provides a much cleaner interface.\r\n\r\nThis PR reconfigures the Server, the C-Client, the UI, the PTZ-Capture-Tool, and also the Python-API. It contains Unit- and Integration-Tests that ensures that the Signal-Handlers actually fire in the right Way.\r\n\r\nfixes #172 by removing the concept of a role","created_at":"2015-01-29T22:37:45Z","updated_at":"2015-01-30T08:18:18Z","closed_at":null,"merged_at":null,"merge_commit_sha":"660a733da3d6c4c83dc19264a90a878a08c42dd7","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/timvideos/gst-switch/pulls/184/commits","review_comments_url":"https://api.github.com/repos/timvideos/gst-switch/pulls/184/comments","review_comment_url":"https://api.github.com/repos/timvideos/gst-switch/pulls/comments/{number}","comments_url":"https://api.github.com/repos/timvideos/gst-switch/issues/184/comments","statuses_url":"https://api.github.com/repos/timvideos/gst-switch/statuses/a2ecdd5a3e5b35ef262146ea7728f5c9e7bcd854","head":{"label":"MaZderMind:dbus-api-signals","ref":"dbus-api-signals","sha":"a2ecdd5a3e5b35ef262146ea7728f5c9e7bcd854","user":{"login":"MaZderMind","id":142237,"avatar_url":"https://avatars.githubusercontent.com/u/142237?v=3","gravatar_id":"","url":"https://api.github.com/users/MaZderMind","html_url":"https://github.com/MaZderMind","followers_url":"https://api.github.com/users/MaZderMind/followers","following_url":"https://api.github.com/users/MaZderMind/following{/other_user}","gists_url":"https://api.github.com/users/MaZderMind/gists{/gist_id}","starred_url":"https://api.github.com/users/MaZderMind/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MaZderMind/subscriptions","organizations_url":"https://api.github.com/users/MaZderMind/orgs","repos_url":"https://api.github.com/users/MaZderMind/repos","events_url":"https://api.github.com/users/MaZderMind/events{/privacy}","received_events_url":"https://api.github.com/users/MaZderMind/received_events","type":"User","site_admin":false},"repo":{"id":28911980,"name":"gst-switch","full_name":"MaZderMind/gst-switch","owner":{"login":"MaZderMind","id":142237,"avatar_url":"https://avatars.githubusercontent.com/u/142237?v=3","gravatar_id":"","url":"https://api.github.com/users/MaZderMind","html_url":"https://github.com/MaZderMind","followers_url":"https://api.github.com/users/MaZderMind/followers","following_url":"https://api.github.com/users/MaZderMind/following{/other_user}","gists_url":"https://api.github.com/users/MaZderMind/gists{/gist_id}","starred_url":"https://api.github.com/users/MaZderMind/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MaZderMind/subscriptions","organizations_url":"https://api.github.com/users/MaZderMind/orgs","repos_url":"https://api.github.com/users/MaZderMind/repos","events_url":"https://api.github.com/users/MaZderMind/events{/privacy}","received_events_url":"https://api.github.com/users/MaZderMind/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/MaZderMind/gst-switch","description":"A DVswitch replacement basing on GStreamer.","fork":true,"url":"https://api.github.com/repos/MaZderMind/gst-switch","forks_url":"https://api.github.com/repos/MaZderMind/gst-switch/forks","keys_url":"https://api.github.com/repos/MaZderMind/gst-switch/keys{/key_id}","collaborators_url":"https://api.github.com/repos/MaZderMind/gst-switch/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/MaZderMind/gst-switch/teams","hooks_url":"https://api.github.com/repos/MaZderMind/gst-switch/hooks","issue_events_url":"https://api.github.com/repos/MaZderMind/gst-switch/issues/events{/number}","events_url":"https://api.github.com/repos/MaZderMind/gst-switch/events","assignees_url":"https://api.github.com/repos/MaZderMind/gst-switch/assignees{/user}","branches_url":"https://api.github.com/repos/MaZderMind/gst-switch/branches{/branch}","tags_url":"https://api.github.com/repos/MaZderMind/gst-switch/tags","blobs_url":"https://api.github.com/repos/MaZderMind/gst-switch/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/MaZderMind/gst-switch/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/MaZderMind/gst-switch/git/refs{/sha}","trees_url":"https://api.github.com/repos/MaZderMind/gst-switch/git/trees{/sha}","statuses_url":"https://api.github.com/repos/MaZderMind/gst-switch/statuses/{sha}","languages_url":"https://api.github.com/repos/MaZderMind/gst-switch/languages","stargazers_url":"https://api.github.com/repos/MaZderMind/gst-switch/stargazers","contributors_url":"https://api.github.com/repos/MaZderMind/gst-switch/contributors","subscribers_url":"https://api.github.com/repos/MaZderMind/gst-switch/subscribers","subscription_url":"https://api.github.com/repos/MaZderMind/gst-switch/subscription","commits_url":"https://api.github.com/repos/MaZderMind/gst-switch/commits{/sha}","git_commits_url":"https://api.github.com/repos/MaZderMind/gst-switch/git/commits{/sha}","comments_url":"https://api.github.com/repos/MaZderMind/gst-switch/comments{/number}","issue_comment_url":"https://api.github.com/repos/MaZderMind/gst-switch/issues/comments/{number}","contents_url":"https://api.github.com/repos/MaZderMind/gst-switch/contents/{+path}","compare_url":"https://api.github.com/repos/MaZderMind/gst-switch/compare/{base}...{head}","merges_url":"https://api.github.com/repos/MaZderMind/gst-switch/merges","archive_url":"https://api.github.com/repos/MaZderMind/gst-switch/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/MaZderMind/gst-switch/downloads","issues_url":"https://api.github.com/repos/MaZderMind/gst-switch/issues{/number}","pulls_url":"https://api.github.com/repos/MaZderMind/gst-switch/pulls{/number}","milestones_url":"https://api.github.com/repos/MaZderMind/gst-switch/milestones{/number}","notifications_url":"https://api.github.com/repos/MaZderMind/gst-switch/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/MaZderMind/gst-switch/labels{/name}","releases_url":"https://api.github.com/repos/MaZderMind/gst-switch/releases{/id}","created_at":"2015-01-07T11:38:59Z","updated_at":"2015-01-11T12:49:13Z","pushed_at":"2015-01-29T22:38:52Z","git_url":"git://github.com/MaZderMind/gst-switch.git","ssh_url":"git@github.com:MaZderMind/gst-switch.git","clone_url":"https://github.com/MaZderMind/gst-switch.git","svn_url":"https://github.com/MaZderMind/gst-switch","homepage":null,"size":3238,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"timvideos:master","ref":"master","sha":"47600c7db2ea59307273e048fa0d201d84771c49","user":{"login":"timvideos","id":811205,"avatar_url":"https://avatars.githubusercontent.com/u/811205?v=3","gravatar_id":"","url":"https://api.github.com/users/timvideos","html_url":"https://github.com/timvideos","followers_url":"https://api.github.com/users/timvideos/followers","following_url":"https://api.github.com/users/timvideos/following{/other_user}","gists_url":"https://api.github.com/users/timvideos/gists{/gist_id}","starred_url":"https://api.github.com/users/timvideos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timvideos/subscriptions","organizations_url":"https://api.github.com/users/timvideos/orgs","repos_url":"https://api.github.com/users/timvideos/repos","events_url":"https://api.github.com/users/timvideos/events{/privacy}","received_events_url":"https://api.github.com/users/timvideos/received_events","type":"Organization","site_admin":false},"repo":{"id":7572862,"name":"gst-switch","full_name":"timvideos/gst-switch","owner":{"login":"timvideos","id":811205,"avatar_url":"https://avatars.githubusercontent.com/u/811205?v=3","gravatar_id":"","url":"https://api.github.com/users/timvideos","html_url":"https://github.com/timvideos","followers_url":"https://api.github.com/users/timvideos/followers","following_url":"https://api.github.com/users/timvideos/following{/other_user}","gists_url":"https://api.github.com/users/timvideos/gists{/gist_id}","starred_url":"https://api.github.com/users/timvideos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timvideos/subscriptions","organizations_url":"https://api.github.com/users/timvideos/orgs","repos_url":"https://api.github.com/users/timvideos/repos","events_url":"https://api.github.com/users/timvideos/events{/privacy}","received_events_url":"https://api.github.com/users/timvideos/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/timvideos/gst-switch","description":"A DVswitch replacement basing on GStreamer.","fork":true,"url":"https://api.github.com/repos/timvideos/gst-switch","forks_url":"https://api.github.com/repos/timvideos/gst-switch/forks","keys_url":"https://api.github.com/repos/timvideos/gst-switch/keys{/key_id}","collaborators_url":"https://api.github.com/repos/timvideos/gst-switch/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/timvideos/gst-switch/teams","hooks_url":"https://api.github.com/repos/timvideos/gst-switch/hooks","issue_events_url":"https://api.github.com/repos/timvideos/gst-switch/issues/events{/number}","events_url":"https://api.github.com/repos/timvideos/gst-switch/events","assignees_url":"https://api.github.com/repos/timvideos/gst-switch/assignees{/user}","branches_url":"https://api.github.com/repos/timvideos/gst-switch/branches{/branch}","tags_url":"https://api.github.com/repos/timvideos/gst-switch/tags","blobs_url":"https://api.github.com/repos/timvideos/gst-switch/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/timvideos/gst-switch/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/timvideos/gst-switch/git/refs{/sha}","trees_url":"https://api.github.com/repos/timvideos/gst-switch/git/trees{/sha}","statuses_url":"https://api.github.com/repos/timvideos/gst-switch/statuses/{sha}","languages_url":"https://api.github.com/repos/timvideos/gst-switch/languages","stargazers_url":"https://api.github.com/repos/timvideos/gst-switch/stargazers","contributors_url":"https://api.github.com/repos/timvideos/gst-switch/contributors","subscribers_url":"https://api.github.com/repos/timvideos/gst-switch/subscribers","subscription_url":"https://api.github.com/repos/timvideos/gst-switch/subscription","commits_url":"https://api.github.com/repos/timvideos/gst-switch/commits{/sha}","git_commits_url":"https://api.github.com/repos/timvideos/gst-switch/git/commits{/sha}","comments_url":"https://api.github.com/repos/timvideos/gst-switch/comments{/number}","issue_comment_url":"https://api.github.com/repos/timvideos/gst-switch/issues/comments/{number}","contents_url":"https://api.github.com/repos/timvideos/gst-switch/contents/{+path}","compare_url":"https://api.github.com/repos/timvideos/gst-switch/compare/{base}...{head}","merges_url":"https://api.github.com/repos/timvideos/gst-switch/merges","archive_url":"https://api.github.com/repos/timvideos/gst-switch/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/timvideos/gst-switch/downloads","issues_url":"https://api.github.com/repos/timvideos/gst-switch/issues{/number}","pulls_url":"https://api.github.com/repos/timvideos/gst-switch/pulls{/number}","milestones_url":"https://api.github.com/repos/timvideos/gst-switch/milestones{/number}","notifications_url":"https://api.github.com/repos/timvideos/gst-switch/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/timvideos/gst-switch/labels{/name}","releases_url":"https://api.github.com/repos/timvideos/gst-switch/releases{/id}","created_at":"2013-01-12T07:31:28Z","updated_at":"2015-01-25T09:30:30Z","pushed_at":"2015-01-25T09:30:30Z","git_url":"git://github.com/timvideos/gst-switch.git","ssh_url":"git@github.com:timvideos/gst-switch.git","clone_url":"https://github.com/timvideos/gst-switch.git","svn_url":"https://github.com/timvideos/gst-switch","homepage":null,"size":4512,"stargazers_count":19,"watchers_count":19,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"open_issues_count":80,"forks":7,"open_issues":80,"watchers":19,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/timvideos/gst-switch/pulls/184"},"html":{"href":"https://github.com/timvideos/gst-switch/pull/184"},"issue":{"href":"https://api.github.com/repos/timvideos/gst-switch/issues/184"},"comments":{"href":"https://api.github.com/repos/timvideos/gst-switch/issues/184/comments"},"review_comments":{"href":"https://api.github.com/repos/timvideos/gst-switch/pulls/184/comments"},"review_comment":{"href":"https://api.github.com/repos/timvideos/gst-switch/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/timvideos/gst-switch/pulls/184/commits"},"statuses":{"href":"https://api.github.com/repos/timvideos/gst-switch/statuses/a2ecdd5a3e5b35ef262146ea7728f5c9e7bcd854"}}}}