{"action":"created","comment":{"url":"https://api.github.com/repos/szeged/servo/pulls/comments/56950045","id":56950045,"diff_hunk":"@@ -0,0 +1,54 @@\n+<!DOCTYPE html>\n+<html>\n+<title>Characteristic info</title>\n+<body>\n+    <button type=\"button\" onclick=\"onButtonClick()\">Read Characteristic</button>\n+    <pre id=\"log\"></pre>\n+    <script>\n+    function onButtonClick() {\n+        clear();\n+        log('Requesting Bluetooth Device...');\n+        try {\n+            var device = window.navigator.bluetooth.requestDevice();\n+            if (device === undefined) throw 'Device not found';\n+            var server = device.gatt.connect();\n+            if (server === undefined) throw 'Server not found on Device';\n+            if (!server.connected) throw 'Server not connected';\n+            log('Requesting Primary Service...');\n+            var primaryService = server.getPrimaryService();\n+            if (primaryService === null) throw 'Primary Service not found';\n+            log('Requesting Characteristic...');\n+            var characteristic = primaryService.getCharacteristic();\n+            if ( characteristic === null) throw 'Characteristic not found';\n+            log('Found a Characteristic !')\n+            log(\"> Characteristic's service: \" + characteristic.service.uuid)\n+            log('> Characteristic UUID:      ' + characteristic.uuid);\n+            log('> Broadcast:                ' + characteristic.properties.broadcast);\n+            log('> Read:                     ' + characteristic.properties.read);\n+            log('> Write w/o response:       ' + characteristic.properties.writeWithoutResponse);\n+            log('> Write:                    ' + characteristic.properties.write);\n+            log('> Notify:                   ' + characteristic.properties.notify);\n+            log('> Indicate:                 ' + characteristic.properties.indicate);\n+            log('> Signed Write:             ' + characteristic.properties.authenticatedSignedWrites);\n+            log('> Queued Write:             ' + characteristic.properties.reliableWrite);\n+            log('> Writable Auxiliaries:     ' + characteristic.properties.writableAuxiliaries);\n+            characteristic.readValue();\n+            log('> Characteristic value:     ' + characteristic.value);\n+        } catch(err) {\n+                log(err);\n+        }\n+    }\n+\n+    function clear() {\n+        document.getElementById(\"log\").textContent = \"\";\n+    }\n+\n+    function log() {\n+        var line = Array.prototype.slice.call(arguments).map(function(argument) {\n+            return typeof argument === 'string' ? argument : JSON.stringify(argument);\n+        }).join(' ');","path":"tests/html/bluetooth_characteristic_info.html","position":49,"original_position":49,"commit_id":"91ce27d37ab2c87735cb21384703c8ccb587e02d","original_commit_id":"1c1e689fd099c18147ad765242e0266c13f84525","user":{"login":"dati91","id":2149430,"avatar_url":"https://avatars.githubusercontent.com/u/2149430?v=3","gravatar_id":"","url":"https://api.github.com/users/dati91","html_url":"https://github.com/dati91","followers_url":"https://api.github.com/users/dati91/followers","following_url":"https://api.github.com/users/dati91/following{/other_user}","gists_url":"https://api.github.com/users/dati91/gists{/gist_id}","starred_url":"https://api.github.com/users/dati91/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dati91/subscriptions","organizations_url":"https://api.github.com/users/dati91/orgs","repos_url":"https://api.github.com/users/dati91/repos","events_url":"https://api.github.com/users/dati91/events{/privacy}","received_events_url":"https://api.github.com/users/dati91/received_events","type":"User","site_admin":false},"body":"maybe this could work?\r\n```\r\nfunction log(line) {\r\n    document.getElementById(\"log\").textContent += line + '\\n';\r\n}\r\n```","created_at":"2016-03-22T08:25:08Z","updated_at":"2016-03-22T08:25:08Z","html_url":"https://github.com/szeged/servo/pull/8#discussion_r56950045","pull_request_url":"https://api.github.com/repos/szeged/servo/pulls/8","_links":{"self":{"href":"https://api.github.com/repos/szeged/servo/pulls/comments/56950045"},"html":{"href":"https://github.com/szeged/servo/pull/8#discussion_r56950045"},"pull_request":{"href":"https://api.github.com/repos/szeged/servo/pulls/8"}}},"pull_request":{"url":"https://api.github.com/repos/szeged/servo/pulls/8","id":63564086,"html_url":"https://github.com/szeged/servo/pull/8","diff_url":"https://github.com/szeged/servo/pull/8.diff","patch_url":"https://github.com/szeged/servo/pull/8.patch","issue_url":"https://api.github.com/repos/szeged/servo/issues/8","number":8,"state":"open","locked":false,"title":"html tests for WBT API methods","user":{"login":"zakorgy","id":11725775,"avatar_url":"https://avatars.githubusercontent.com/u/11725775?v=3","gravatar_id":"","url":"https://api.github.com/users/zakorgy","html_url":"https://github.com/zakorgy","followers_url":"https://api.github.com/users/zakorgy/followers","following_url":"https://api.github.com/users/zakorgy/following{/other_user}","gists_url":"https://api.github.com/users/zakorgy/gists{/gist_id}","starred_url":"https://api.github.com/users/zakorgy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zakorgy/subscriptions","organizations_url":"https://api.github.com/users/zakorgy/orgs","repos_url":"https://api.github.com/users/zakorgy/repos","events_url":"https://api.github.com/users/zakorgy/events{/privacy}","received_events_url":"https://api.github.com/users/zakorgy/received_events","type":"User","site_admin":false},"body":"requestDevice(), getPrimaryservice(), getCharacteristic() and getDescriptor()","created_at":"2016-03-21T13:34:06Z","updated_at":"2016-03-22T08:25:09Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c6c6c12d1df14b9ea468f4f449ea3a799be890c9","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/szeged/servo/pulls/8/commits","review_comments_url":"https://api.github.com/repos/szeged/servo/pulls/8/comments","review_comment_url":"https://api.github.com/repos/szeged/servo/pulls/comments{/number}","comments_url":"https://api.github.com/repos/szeged/servo/issues/8/comments","statuses_url":"https://api.github.com/repos/szeged/servo/statuses/91ce27d37ab2c87735cb21384703c8ccb587e02d","head":{"label":"zakorgy:bluetooth-ipc","ref":"bluetooth-ipc","sha":"91ce27d37ab2c87735cb21384703c8ccb587e02d","user":{"login":"zakorgy","id":11725775,"avatar_url":"https://avatars.githubusercontent.com/u/11725775?v=3","gravatar_id":"","url":"https://api.github.com/users/zakorgy","html_url":"https://github.com/zakorgy","followers_url":"https://api.github.com/users/zakorgy/followers","following_url":"https://api.github.com/users/zakorgy/following{/other_user}","gists_url":"https://api.github.com/users/zakorgy/gists{/gist_id}","starred_url":"https://api.github.com/users/zakorgy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zakorgy/subscriptions","organizations_url":"https://api.github.com/users/zakorgy/orgs","repos_url":"https://api.github.com/users/zakorgy/repos","events_url":"https://api.github.com/users/zakorgy/events{/privacy}","received_events_url":"https://api.github.com/users/zakorgy/received_events","type":"User","site_admin":false},"repo":{"id":53485776,"name":"servo","full_name":"zakorgy/servo","owner":{"login":"zakorgy","id":11725775,"avatar_url":"https://avatars.githubusercontent.com/u/11725775?v=3","gravatar_id":"","url":"https://api.github.com/users/zakorgy","html_url":"https://github.com/zakorgy","followers_url":"https://api.github.com/users/zakorgy/followers","following_url":"https://api.github.com/users/zakorgy/following{/other_user}","gists_url":"https://api.github.com/users/zakorgy/gists{/gist_id}","starred_url":"https://api.github.com/users/zakorgy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zakorgy/subscriptions","organizations_url":"https://api.github.com/users/zakorgy/orgs","repos_url":"https://api.github.com/users/zakorgy/repos","events_url":"https://api.github.com/users/zakorgy/events{/privacy}","received_events_url":"https://api.github.com/users/zakorgy/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/zakorgy/servo","description":"The Servo Browser Engine","fork":true,"url":"https://api.github.com/repos/zakorgy/servo","forks_url":"https://api.github.com/repos/zakorgy/servo/forks","keys_url":"https://api.github.com/repos/zakorgy/servo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/zakorgy/servo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/zakorgy/servo/teams","hooks_url":"https://api.github.com/repos/zakorgy/servo/hooks","issue_events_url":"https://api.github.com/repos/zakorgy/servo/issues/events{/number}","events_url":"https://api.github.com/repos/zakorgy/servo/events","assignees_url":"https://api.github.com/repos/zakorgy/servo/assignees{/user}","branches_url":"https://api.github.com/repos/zakorgy/servo/branches{/branch}","tags_url":"https://api.github.com/repos/zakorgy/servo/tags","blobs_url":"https://api.github.com/repos/zakorgy/servo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/zakorgy/servo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/zakorgy/servo/git/refs{/sha}","trees_url":"https://api.github.com/repos/zakorgy/servo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/zakorgy/servo/statuses/{sha}","languages_url":"https://api.github.com/repos/zakorgy/servo/languages","stargazers_url":"https://api.github.com/repos/zakorgy/servo/stargazers","contributors_url":"https://api.github.com/repos/zakorgy/servo/contributors","subscribers_url":"https://api.github.com/repos/zakorgy/servo/subscribers","subscription_url":"https://api.github.com/repos/zakorgy/servo/subscription","commits_url":"https://api.github.com/repos/zakorgy/servo/commits{/sha}","git_commits_url":"https://api.github.com/repos/zakorgy/servo/git/commits{/sha}","comments_url":"https://api.github.com/repos/zakorgy/servo/comments{/number}","issue_comment_url":"https://api.github.com/repos/zakorgy/servo/issues/comments{/number}","contents_url":"https://api.github.com/repos/zakorgy/servo/contents/{+path}","compare_url":"https://api.github.com/repos/zakorgy/servo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/zakorgy/servo/merges","archive_url":"https://api.github.com/repos/zakorgy/servo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/zakorgy/servo/downloads","issues_url":"https://api.github.com/repos/zakorgy/servo/issues{/number}","pulls_url":"https://api.github.com/repos/zakorgy/servo/pulls{/number}","milestones_url":"https://api.github.com/repos/zakorgy/servo/milestones{/number}","notifications_url":"https://api.github.com/repos/zakorgy/servo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/zakorgy/servo/labels{/name}","releases_url":"https://api.github.com/repos/zakorgy/servo/releases{/id}","deployments_url":"https://api.github.com/repos/zakorgy/servo/deployments","created_at":"2016-03-09T09:36:07Z","updated_at":"2016-01-25T13:06:41Z","pushed_at":"2016-03-21T15:30:07Z","git_url":"git://github.com/zakorgy/servo.git","ssh_url":"git@github.com:zakorgy/servo.git","clone_url":"https://github.com/zakorgy/servo.git","svn_url":"https://github.com/zakorgy/servo","homepage":"https://servo.org/","size":178749,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":false,"has_downloads":true,"has_wiki":true,"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":"szeged:bluetooth-ipc","ref":"bluetooth-ipc","sha":"61fd9028e611f1a6758fdf2acea8639abeb7be61","user":{"login":"szeged","id":1826696,"avatar_url":"https://avatars.githubusercontent.com/u/1826696?v=3","gravatar_id":"","url":"https://api.github.com/users/szeged","html_url":"https://github.com/szeged","followers_url":"https://api.github.com/users/szeged/followers","following_url":"https://api.github.com/users/szeged/following{/other_user}","gists_url":"https://api.github.com/users/szeged/gists{/gist_id}","starred_url":"https://api.github.com/users/szeged/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/szeged/subscriptions","organizations_url":"https://api.github.com/users/szeged/orgs","repos_url":"https://api.github.com/users/szeged/repos","events_url":"https://api.github.com/users/szeged/events{/privacy}","received_events_url":"https://api.github.com/users/szeged/received_events","type":"Organization","site_admin":false},"repo":{"id":50353354,"name":"servo","full_name":"szeged/servo","owner":{"login":"szeged","id":1826696,"avatar_url":"https://avatars.githubusercontent.com/u/1826696?v=3","gravatar_id":"","url":"https://api.github.com/users/szeged","html_url":"https://github.com/szeged","followers_url":"https://api.github.com/users/szeged/followers","following_url":"https://api.github.com/users/szeged/following{/other_user}","gists_url":"https://api.github.com/users/szeged/gists{/gist_id}","starred_url":"https://api.github.com/users/szeged/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/szeged/subscriptions","organizations_url":"https://api.github.com/users/szeged/orgs","repos_url":"https://api.github.com/users/szeged/repos","events_url":"https://api.github.com/users/szeged/events{/privacy}","received_events_url":"https://api.github.com/users/szeged/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/szeged/servo","description":"The Servo Browser Engine","fork":true,"url":"https://api.github.com/repos/szeged/servo","forks_url":"https://api.github.com/repos/szeged/servo/forks","keys_url":"https://api.github.com/repos/szeged/servo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/szeged/servo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/szeged/servo/teams","hooks_url":"https://api.github.com/repos/szeged/servo/hooks","issue_events_url":"https://api.github.com/repos/szeged/servo/issues/events{/number}","events_url":"https://api.github.com/repos/szeged/servo/events","assignees_url":"https://api.github.com/repos/szeged/servo/assignees{/user}","branches_url":"https://api.github.com/repos/szeged/servo/branches{/branch}","tags_url":"https://api.github.com/repos/szeged/servo/tags","blobs_url":"https://api.github.com/repos/szeged/servo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/szeged/servo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/szeged/servo/git/refs{/sha}","trees_url":"https://api.github.com/repos/szeged/servo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/szeged/servo/statuses/{sha}","languages_url":"https://api.github.com/repos/szeged/servo/languages","stargazers_url":"https://api.github.com/repos/szeged/servo/stargazers","contributors_url":"https://api.github.com/repos/szeged/servo/contributors","subscribers_url":"https://api.github.com/repos/szeged/servo/subscribers","subscription_url":"https://api.github.com/repos/szeged/servo/subscription","commits_url":"https://api.github.com/repos/szeged/servo/commits{/sha}","git_commits_url":"https://api.github.com/repos/szeged/servo/git/commits{/sha}","comments_url":"https://api.github.com/repos/szeged/servo/comments{/number}","issue_comment_url":"https://api.github.com/repos/szeged/servo/issues/comments{/number}","contents_url":"https://api.github.com/repos/szeged/servo/contents/{+path}","compare_url":"https://api.github.com/repos/szeged/servo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/szeged/servo/merges","archive_url":"https://api.github.com/repos/szeged/servo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/szeged/servo/downloads","issues_url":"https://api.github.com/repos/szeged/servo/issues{/number}","pulls_url":"https://api.github.com/repos/szeged/servo/pulls{/number}","milestones_url":"https://api.github.com/repos/szeged/servo/milestones{/number}","notifications_url":"https://api.github.com/repos/szeged/servo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/szeged/servo/labels{/name}","releases_url":"https://api.github.com/repos/szeged/servo/releases{/id}","deployments_url":"https://api.github.com/repos/szeged/servo/deployments","created_at":"2016-01-25T13:48:48Z","updated_at":"2016-01-25T13:06:41Z","pushed_at":"2016-03-21T15:30:10Z","git_url":"git://github.com/szeged/servo.git","ssh_url":"git@github.com:szeged/servo.git","clone_url":"https://github.com/szeged/servo.git","svn_url":"https://github.com/szeged/servo","homepage":"https://servo.org/","size":178857,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":1,"forks":3,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/szeged/servo/pulls/8"},"html":{"href":"https://github.com/szeged/servo/pull/8"},"issue":{"href":"https://api.github.com/repos/szeged/servo/issues/8"},"comments":{"href":"https://api.github.com/repos/szeged/servo/issues/8/comments"},"review_comments":{"href":"https://api.github.com/repos/szeged/servo/pulls/8/comments"},"review_comment":{"href":"https://api.github.com/repos/szeged/servo/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/szeged/servo/pulls/8/commits"},"statuses":{"href":"https://api.github.com/repos/szeged/servo/statuses/91ce27d37ab2c87735cb21384703c8ccb587e02d"}}}}