{"action":"created","comment":{"url":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/comments/93134258","pull_request_review_id":13656488,"id":93134258,"diff_hunk":"@@ -0,0 +1,57 @@\n+describe('Filtering by demographics', () => {\n+  describe('#lengthOfStay', () => {\n+    it('returns the correct length of stay for an active booking', () => {\n+      const booking = {\n+        booking_date_time: \"2016-12-11T13:13:17.000Z\",\n+        release_date_time: null\n+      }\n+\n+      const table = new FilterTable();\n+\n+      let expectedDifference = new Date() - new Date(booking.booking_date_time);\n+      expect(table.lengthOfStay(booking)).toBeCloseTo(expectedDifference);\n+    });\n+\n+    it('returns the correct length of stay for an inactive booking', () => {\n+      const booking = {\n+        booking_date_time: \"2016-12-11T13:13:17.000Z\",\n+        release_date_time: \"2018-12-11T13:13:17.000Z\"\n+      }\n+\n+      const table = new FilterTable();\n+\n+      let expectedDifference = new Date(booking.release_date_time) - new Date(booking.booking_date_time);\n+      expect(table.lengthOfStay(booking)).toEqual(expectedDifference);\n+    });\n+  });\n+\n+  describe('#distanceOfTimeInWords', () => {\n+    it('can handle days', () => {\n+      const table = new FilterTable();\n+\n+      const duration = new Date(2016, 1, 3) - new Date(2016, 1, 1)","path":"spec/javascripts/filterSpec.js","position":32,"original_position":32,"commit_id":"0d1bcba99e3ec2923f5064cf77bc0ffb73ef99d6","original_commit_id":"0d1bcba99e3ec2923f5064cf77bc0ffb73ef99d6","user":{"login":"houndci-bot","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci-bot","html_url":"https://github.com/houndci-bot","followers_url":"https://api.github.com/users/houndci-bot/followers","following_url":"https://api.github.com/users/houndci-bot/following{/other_user}","gists_url":"https://api.github.com/users/houndci-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci-bot/subscriptions","organizations_url":"https://api.github.com/users/houndci-bot/orgs","repos_url":"https://api.github.com/users/houndci-bot/repos","events_url":"https://api.github.com/users/houndci-bot/events{/privacy}","received_events_url":"https://api.github.com/users/houndci-bot/received_events","type":"User","site_admin":false},"body":"Missing semicolon             semi","created_at":"2016-12-19T22:31:13Z","updated_at":"2016-12-19T22:31:13Z","html_url":"https://github.com/codeforamerica/jail-dashboard/pull/88#discussion_r93134258","pull_request_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/88","_links":{"self":{"href":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/comments/93134258"},"html":{"href":"https://github.com/codeforamerica/jail-dashboard/pull/88#discussion_r93134258"},"pull_request":{"href":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/88"}}},"pull_request":{"url":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/88","id":98652251,"html_url":"https://github.com/codeforamerica/jail-dashboard/pull/88","diff_url":"https://github.com/codeforamerica/jail-dashboard/pull/88.diff","patch_url":"https://github.com/codeforamerica/jail-dashboard/pull/88.patch","issue_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/issues/88","number":88,"state":"open","locked":false,"title":"Add table entries for Length of Stay","user":{"login":"graysonwright","id":829576,"avatar_url":"https://avatars.githubusercontent.com/u/829576?v=3","gravatar_id":"","url":"https://api.github.com/users/graysonwright","html_url":"https://github.com/graysonwright","followers_url":"https://api.github.com/users/graysonwright/followers","following_url":"https://api.github.com/users/graysonwright/following{/other_user}","gists_url":"https://api.github.com/users/graysonwright/gists{/gist_id}","starred_url":"https://api.github.com/users/graysonwright/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/graysonwright/subscriptions","organizations_url":"https://api.github.com/users/graysonwright/orgs","repos_url":"https://api.github.com/users/graysonwright/repos","events_url":"https://api.github.com/users/graysonwright/events{/privacy}","received_events_url":"https://api.github.com/users/graysonwright/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-12-19T22:30:19Z","updated_at":"2016-12-19T22:31:13Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4eebbda30cec72eee98bd1d7b74bd1fa27753148","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/88/commits","review_comments_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/88/comments","review_comment_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/comments{/number}","comments_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/issues/88/comments","statuses_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/statuses/0d1bcba99e3ec2923f5064cf77bc0ffb73ef99d6","head":{"label":"codeforamerica:los","ref":"los","sha":"0d1bcba99e3ec2923f5064cf77bc0ffb73ef99d6","user":{"login":"codeforamerica","id":337792,"avatar_url":"https://avatars.githubusercontent.com/u/337792?v=3","gravatar_id":"","url":"https://api.github.com/users/codeforamerica","html_url":"https://github.com/codeforamerica","followers_url":"https://api.github.com/users/codeforamerica/followers","following_url":"https://api.github.com/users/codeforamerica/following{/other_user}","gists_url":"https://api.github.com/users/codeforamerica/gists{/gist_id}","starred_url":"https://api.github.com/users/codeforamerica/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codeforamerica/subscriptions","organizations_url":"https://api.github.com/users/codeforamerica/orgs","repos_url":"https://api.github.com/users/codeforamerica/repos","events_url":"https://api.github.com/users/codeforamerica/events{/privacy}","received_events_url":"https://api.github.com/users/codeforamerica/received_events","type":"Organization","site_admin":false},"repo":{"id":72130706,"name":"jail-dashboard","full_name":"codeforamerica/jail-dashboard","owner":{"login":"codeforamerica","id":337792,"avatar_url":"https://avatars.githubusercontent.com/u/337792?v=3","gravatar_id":"","url":"https://api.github.com/users/codeforamerica","html_url":"https://github.com/codeforamerica","followers_url":"https://api.github.com/users/codeforamerica/followers","following_url":"https://api.github.com/users/codeforamerica/following{/other_user}","gists_url":"https://api.github.com/users/codeforamerica/gists{/gist_id}","starred_url":"https://api.github.com/users/codeforamerica/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codeforamerica/subscriptions","organizations_url":"https://api.github.com/users/codeforamerica/orgs","repos_url":"https://api.github.com/users/codeforamerica/repos","events_url":"https://api.github.com/users/codeforamerica/events{/privacy}","received_events_url":"https://api.github.com/users/codeforamerica/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/codeforamerica/jail-dashboard","description":"A tool to help jail administrators, judges, and other stakeholders understand the conditions in metro jails, and use this data to visualize how their decisions–at both the individual and policy level–affect program, facility, and inmate outcomes.","fork":false,"url":"https://api.github.com/repos/codeforamerica/jail-dashboard","forks_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/forks","keys_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/keys{/key_id}","collaborators_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/teams","hooks_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/hooks","issue_events_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/issues/events{/number}","events_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/events","assignees_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/assignees{/user}","branches_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/branches{/branch}","tags_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/tags","blobs_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/git/refs{/sha}","trees_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/git/trees{/sha}","statuses_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/statuses/{sha}","languages_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/languages","stargazers_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/stargazers","contributors_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/contributors","subscribers_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/subscribers","subscription_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/subscription","commits_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/commits{/sha}","git_commits_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/git/commits{/sha}","comments_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/comments{/number}","issue_comment_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/issues/comments{/number}","contents_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/contents/{+path}","compare_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/compare/{base}...{head}","merges_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/merges","archive_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/downloads","issues_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/issues{/number}","pulls_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls{/number}","milestones_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/milestones{/number}","notifications_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/labels{/name}","releases_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/releases{/id}","deployments_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/deployments","created_at":"2016-10-27T17:14:21Z","updated_at":"2016-12-14T23:30:55Z","pushed_at":"2016-12-19T22:30:19Z","git_url":"git://github.com/codeforamerica/jail-dashboard.git","ssh_url":"git@github.com:codeforamerica/jail-dashboard.git","clone_url":"https://github.com/codeforamerica/jail-dashboard.git","svn_url":"https://github.com/codeforamerica/jail-dashboard","homepage":null,"size":24955,"stargazers_count":1,"watchers_count":1,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":8,"forks":0,"open_issues":8,"watchers":1,"default_branch":"master"}},"base":{"label":"codeforamerica:crossfilter","ref":"crossfilter","sha":"974f4bca9588f638599819721d5bc31716bf42a6","user":{"login":"codeforamerica","id":337792,"avatar_url":"https://avatars.githubusercontent.com/u/337792?v=3","gravatar_id":"","url":"https://api.github.com/users/codeforamerica","html_url":"https://github.com/codeforamerica","followers_url":"https://api.github.com/users/codeforamerica/followers","following_url":"https://api.github.com/users/codeforamerica/following{/other_user}","gists_url":"https://api.github.com/users/codeforamerica/gists{/gist_id}","starred_url":"https://api.github.com/users/codeforamerica/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codeforamerica/subscriptions","organizations_url":"https://api.github.com/users/codeforamerica/orgs","repos_url":"https://api.github.com/users/codeforamerica/repos","events_url":"https://api.github.com/users/codeforamerica/events{/privacy}","received_events_url":"https://api.github.com/users/codeforamerica/received_events","type":"Organization","site_admin":false},"repo":{"id":72130706,"name":"jail-dashboard","full_name":"codeforamerica/jail-dashboard","owner":{"login":"codeforamerica","id":337792,"avatar_url":"https://avatars.githubusercontent.com/u/337792?v=3","gravatar_id":"","url":"https://api.github.com/users/codeforamerica","html_url":"https://github.com/codeforamerica","followers_url":"https://api.github.com/users/codeforamerica/followers","following_url":"https://api.github.com/users/codeforamerica/following{/other_user}","gists_url":"https://api.github.com/users/codeforamerica/gists{/gist_id}","starred_url":"https://api.github.com/users/codeforamerica/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codeforamerica/subscriptions","organizations_url":"https://api.github.com/users/codeforamerica/orgs","repos_url":"https://api.github.com/users/codeforamerica/repos","events_url":"https://api.github.com/users/codeforamerica/events{/privacy}","received_events_url":"https://api.github.com/users/codeforamerica/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/codeforamerica/jail-dashboard","description":"A tool to help jail administrators, judges, and other stakeholders understand the conditions in metro jails, and use this data to visualize how their decisions–at both the individual and policy level–affect program, facility, and inmate outcomes.","fork":false,"url":"https://api.github.com/repos/codeforamerica/jail-dashboard","forks_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/forks","keys_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/keys{/key_id}","collaborators_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/teams","hooks_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/hooks","issue_events_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/issues/events{/number}","events_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/events","assignees_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/assignees{/user}","branches_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/branches{/branch}","tags_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/tags","blobs_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/git/refs{/sha}","trees_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/git/trees{/sha}","statuses_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/statuses/{sha}","languages_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/languages","stargazers_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/stargazers","contributors_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/contributors","subscribers_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/subscribers","subscription_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/subscription","commits_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/commits{/sha}","git_commits_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/git/commits{/sha}","comments_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/comments{/number}","issue_comment_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/issues/comments{/number}","contents_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/contents/{+path}","compare_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/compare/{base}...{head}","merges_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/merges","archive_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/downloads","issues_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/issues{/number}","pulls_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls{/number}","milestones_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/milestones{/number}","notifications_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/labels{/name}","releases_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/releases{/id}","deployments_url":"https://api.github.com/repos/codeforamerica/jail-dashboard/deployments","created_at":"2016-10-27T17:14:21Z","updated_at":"2016-12-14T23:30:55Z","pushed_at":"2016-12-19T22:30:19Z","git_url":"git://github.com/codeforamerica/jail-dashboard.git","ssh_url":"git@github.com:codeforamerica/jail-dashboard.git","clone_url":"https://github.com/codeforamerica/jail-dashboard.git","svn_url":"https://github.com/codeforamerica/jail-dashboard","homepage":null,"size":24955,"stargazers_count":1,"watchers_count":1,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":8,"forks":0,"open_issues":8,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/88"},"html":{"href":"https://github.com/codeforamerica/jail-dashboard/pull/88"},"issue":{"href":"https://api.github.com/repos/codeforamerica/jail-dashboard/issues/88"},"comments":{"href":"https://api.github.com/repos/codeforamerica/jail-dashboard/issues/88/comments"},"review_comments":{"href":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/88/comments"},"review_comment":{"href":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/codeforamerica/jail-dashboard/pulls/88/commits"},"statuses":{"href":"https://api.github.com/repos/codeforamerica/jail-dashboard/statuses/0d1bcba99e3ec2923f5064cf77bc0ffb73ef99d6"}}}}
{"actor":{"display_login":"houndci-bot"}}