{"action":"created","comment":{"url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/comments/211457899","pull_request_review_id":147881049,"id":211457899,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxMTQ1Nzg5OQ==","diff_hunk":"@@ -0,0 +1,239 @@\n+package org.sagebionetworks.research.mpower\n+\n+import android.arch.persistence.room.Room\n+import android.support.test.InstrumentationRegistry\n+import android.support.test.runner.AndroidJUnit4\n+import junit.framework.Assert.assertEquals\n+import junit.framework.Assert.assertNotNull\n+import junit.framework.Assert.assertNull\n+import junit.framework.Assert.assertTrue\n+import org.joda.time.DateTime\n+\n+import org.junit.After\n+import org.junit.Before\n+import org.junit.Test\n+import org.junit.runner.RunWith\n+import org.sagebionetworks.bridge.rest.RestUtils\n+import org.sagebionetworks.bridge.rest.model.ScheduleStatus\n+import org.sagebionetworks.bridge.rest.model.ScheduledActivityListV4\n+import org.sagebionetworks.research.mpower.room.ResearchDatabase\n+import org.sagebionetworks.research.mpower.room.RoomScheduledActivity\n+import org.sagebionetworks.research.mpower.room.RoomScheduledActivityDao\n+import org.sagebionetworks.research.mpower.room.RoomTypeConverters\n+import java.io.IOException\n+import java.nio.charset.Charset\n+\n+@RunWith(AndroidJUnit4::class)\n+class RoomScheduledActivityTests {\n+\n+    private var database: ResearchDatabase? = null\n+    private var activityDao: RoomScheduledActivityDao? = null\n+    private var activityList: ScheduledActivityListV4? = null\n+    private var roomActivityList: List<RoomScheduledActivity>? = null\n+\n+    @Before @Test\n+    fun setupRoom() {","path":"app/src/androidTest/java/org/sagebionetworks/research/mpower/RoomScheduledActivityTests.kt","position":35,"original_position":35,"commit_id":"8f61813d0201cebeea44d9f6be4fe75e3b7b73e1","original_commit_id":"8f61813d0201cebeea44d9f6be4fe75e3b7b73e1","user":{"login":"dephillipsmichael","id":5590748,"node_id":"MDQ6VXNlcjU1OTA3NDg=","avatar_url":"https://avatars3.githubusercontent.com/u/5590748?v=4","gravatar_id":"","url":"https://api.github.com/users/dephillipsmichael","html_url":"https://github.com/dephillipsmichael","followers_url":"https://api.github.com/users/dephillipsmichael/followers","following_url":"https://api.github.com/users/dephillipsmichael/following{/other_user}","gists_url":"https://api.github.com/users/dephillipsmichael/gists{/gist_id}","starred_url":"https://api.github.com/users/dephillipsmichael/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dephillipsmichael/subscriptions","organizations_url":"https://api.github.com/users/dephillipsmichael/orgs","repos_url":"https://api.github.com/users/dephillipsmichael/repos","events_url":"https://api.github.com/users/dephillipsmichael/events{/privacy}","received_events_url":"https://api.github.com/users/dephillipsmichael/received_events","type":"User","site_admin":false},"body":"I'm a little embarrassed, but I had no idea that @Before meant before each test, I thought it was equivalent to @BeforeClass.  I'll fix this up.","created_at":"2018-08-21T01:52:37Z","updated_at":"2018-08-21T01:52:37Z","html_url":"https://github.com/Sage-Bionetworks/mPower-2-Android/pull/33#discussion_r211457899","pull_request_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/33","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/comments/211457899"},"html":{"href":"https://github.com/Sage-Bionetworks/mPower-2-Android/pull/33#discussion_r211457899"},"pull_request":{"href":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/33"}},"in_reply_to_id":211446819},"pull_request":{"url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/33","id":209600231,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA5NjAwMjMx","html_url":"https://github.com/Sage-Bionetworks/mPower-2-Android/pull/33","diff_url":"https://github.com/Sage-Bionetworks/mPower-2-Android/pull/33.diff","patch_url":"https://github.com/Sage-Bionetworks/mPower-2-Android/pull/33.patch","issue_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/issues/33","number":33,"state":"open","locked":false,"title":"Room + ScheduledActivity","user":{"login":"dephillipsmichael","id":5590748,"node_id":"MDQ6VXNlcjU1OTA3NDg=","avatar_url":"https://avatars3.githubusercontent.com/u/5590748?v=4","gravatar_id":"","url":"https://api.github.com/users/dephillipsmichael","html_url":"https://github.com/dephillipsmichael","followers_url":"https://api.github.com/users/dephillipsmichael/followers","following_url":"https://api.github.com/users/dephillipsmichael/following{/other_user}","gists_url":"https://api.github.com/users/dephillipsmichael/gists{/gist_id}","starred_url":"https://api.github.com/users/dephillipsmichael/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dephillipsmichael/subscriptions","organizations_url":"https://api.github.com/users/dephillipsmichael/orgs","repos_url":"https://api.github.com/users/dephillipsmichael/repos","events_url":"https://api.github.com/users/dephillipsmichael/events{/privacy}","received_events_url":"https://api.github.com/users/dephillipsmichael/received_events","type":"User","site_admin":false},"body":"This PR introduces some classes that can convert from Bridge's ScheduledActivity objects to a new data structure that is equivalent but can be stored and queried in Room.  I was also able to create android implementation tests for making sure the queries were doing what their iOS equivalents were doing.","created_at":"2018-08-20T18:08:38Z","updated_at":"2018-08-21T01:52:37Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5501703ddf31bcf474b2649fff996e7522759415","assignee":null,"assignees":[],"requested_reviewers":[{"login":"Robert-Kolmos","id":22583398,"node_id":"MDQ6VXNlcjIyNTgzMzk4","avatar_url":"https://avatars1.githubusercontent.com/u/22583398?v=4","gravatar_id":"","url":"https://api.github.com/users/Robert-Kolmos","html_url":"https://github.com/Robert-Kolmos","followers_url":"https://api.github.com/users/Robert-Kolmos/followers","following_url":"https://api.github.com/users/Robert-Kolmos/following{/other_user}","gists_url":"https://api.github.com/users/Robert-Kolmos/gists{/gist_id}","starred_url":"https://api.github.com/users/Robert-Kolmos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Robert-Kolmos/subscriptions","organizations_url":"https://api.github.com/users/Robert-Kolmos/orgs","repos_url":"https://api.github.com/users/Robert-Kolmos/repos","events_url":"https://api.github.com/users/Robert-Kolmos/events{/privacy}","received_events_url":"https://api.github.com/users/Robert-Kolmos/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/33/commits","review_comments_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/33/comments","review_comment_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/issues/33/comments","statuses_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/statuses/8f61813d0201cebeea44d9f6be4fe75e3b7b73e1","head":{"label":"dephillipsmichael:room","ref":"room","sha":"8f61813d0201cebeea44d9f6be4fe75e3b7b73e1","user":{"login":"dephillipsmichael","id":5590748,"node_id":"MDQ6VXNlcjU1OTA3NDg=","avatar_url":"https://avatars3.githubusercontent.com/u/5590748?v=4","gravatar_id":"","url":"https://api.github.com/users/dephillipsmichael","html_url":"https://github.com/dephillipsmichael","followers_url":"https://api.github.com/users/dephillipsmichael/followers","following_url":"https://api.github.com/users/dephillipsmichael/following{/other_user}","gists_url":"https://api.github.com/users/dephillipsmichael/gists{/gist_id}","starred_url":"https://api.github.com/users/dephillipsmichael/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dephillipsmichael/subscriptions","organizations_url":"https://api.github.com/users/dephillipsmichael/orgs","repos_url":"https://api.github.com/users/dephillipsmichael/repos","events_url":"https://api.github.com/users/dephillipsmichael/events{/privacy}","received_events_url":"https://api.github.com/users/dephillipsmichael/received_events","type":"User","site_admin":false},"repo":{"id":144335597,"node_id":"MDEwOlJlcG9zaXRvcnkxNDQzMzU1OTc=","name":"mPower-2-Android","full_name":"dephillipsmichael/mPower-2-Android","owner":{"login":"dephillipsmichael","id":5590748,"node_id":"MDQ6VXNlcjU1OTA3NDg=","avatar_url":"https://avatars3.githubusercontent.com/u/5590748?v=4","gravatar_id":"","url":"https://api.github.com/users/dephillipsmichael","html_url":"https://github.com/dephillipsmichael","followers_url":"https://api.github.com/users/dephillipsmichael/followers","following_url":"https://api.github.com/users/dephillipsmichael/following{/other_user}","gists_url":"https://api.github.com/users/dephillipsmichael/gists{/gist_id}","starred_url":"https://api.github.com/users/dephillipsmichael/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dephillipsmichael/subscriptions","organizations_url":"https://api.github.com/users/dephillipsmichael/orgs","repos_url":"https://api.github.com/users/dephillipsmichael/repos","events_url":"https://api.github.com/users/dephillipsmichael/events{/privacy}","received_events_url":"https://api.github.com/users/dephillipsmichael/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/dephillipsmichael/mPower-2-Android","description":"Source code for the Android version of the mPower 2 study app.","fork":true,"url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android","forks_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/forks","keys_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/teams","hooks_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/hooks","issue_events_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/issues/events{/number}","events_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/events","assignees_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/assignees{/user}","branches_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/branches{/branch}","tags_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/tags","blobs_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/git/refs{/sha}","trees_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/statuses/{sha}","languages_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/languages","stargazers_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/stargazers","contributors_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/contributors","subscribers_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/subscribers","subscription_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/subscription","commits_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/commits{/sha}","git_commits_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/git/commits{/sha}","comments_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/comments{/number}","issue_comment_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/issues/comments{/number}","contents_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/contents/{+path}","compare_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/merges","archive_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/downloads","issues_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/issues{/number}","pulls_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/pulls{/number}","milestones_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/milestones{/number}","notifications_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/labels{/name}","releases_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/releases{/id}","deployments_url":"https://api.github.com/repos/dephillipsmichael/mPower-2-Android/deployments","created_at":"2018-08-10T21:55:45Z","updated_at":"2018-08-10T21:55:47Z","pushed_at":"2018-08-20T22:44:44Z","git_url":"git://github.com/dephillipsmichael/mPower-2-Android.git","ssh_url":"git@github.com:dephillipsmichael/mPower-2-Android.git","clone_url":"https://github.com/dephillipsmichael/mPower-2-Android.git","svn_url":"https://github.com/dephillipsmichael/mPower-2-Android","homepage":null,"size":2739,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":null,"url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"develop"}},"base":{"label":"Sage-Bionetworks:develop","ref":"develop","sha":"c53e87ec7dc8d0289447b06c14ec82f08cca58a3","user":{"login":"Sage-Bionetworks","id":1250897,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEyNTA4OTc=","avatar_url":"https://avatars2.githubusercontent.com/u/1250897?v=4","gravatar_id":"","url":"https://api.github.com/users/Sage-Bionetworks","html_url":"https://github.com/Sage-Bionetworks","followers_url":"https://api.github.com/users/Sage-Bionetworks/followers","following_url":"https://api.github.com/users/Sage-Bionetworks/following{/other_user}","gists_url":"https://api.github.com/users/Sage-Bionetworks/gists{/gist_id}","starred_url":"https://api.github.com/users/Sage-Bionetworks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sage-Bionetworks/subscriptions","organizations_url":"https://api.github.com/users/Sage-Bionetworks/orgs","repos_url":"https://api.github.com/users/Sage-Bionetworks/repos","events_url":"https://api.github.com/users/Sage-Bionetworks/events{/privacy}","received_events_url":"https://api.github.com/users/Sage-Bionetworks/received_events","type":"Organization","site_admin":false},"repo":{"id":125897504,"node_id":"MDEwOlJlcG9zaXRvcnkxMjU4OTc1MDQ=","name":"mPower-2-Android","full_name":"Sage-Bionetworks/mPower-2-Android","owner":{"login":"Sage-Bionetworks","id":1250897,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEyNTA4OTc=","avatar_url":"https://avatars2.githubusercontent.com/u/1250897?v=4","gravatar_id":"","url":"https://api.github.com/users/Sage-Bionetworks","html_url":"https://github.com/Sage-Bionetworks","followers_url":"https://api.github.com/users/Sage-Bionetworks/followers","following_url":"https://api.github.com/users/Sage-Bionetworks/following{/other_user}","gists_url":"https://api.github.com/users/Sage-Bionetworks/gists{/gist_id}","starred_url":"https://api.github.com/users/Sage-Bionetworks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sage-Bionetworks/subscriptions","organizations_url":"https://api.github.com/users/Sage-Bionetworks/orgs","repos_url":"https://api.github.com/users/Sage-Bionetworks/repos","events_url":"https://api.github.com/users/Sage-Bionetworks/events{/privacy}","received_events_url":"https://api.github.com/users/Sage-Bionetworks/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Sage-Bionetworks/mPower-2-Android","description":"Source code for the Android version of the mPower 2 study app.","fork":false,"url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android","forks_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/forks","keys_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/teams","hooks_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/hooks","issue_events_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/issues/events{/number}","events_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/events","assignees_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/assignees{/user}","branches_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/branches{/branch}","tags_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/tags","blobs_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/git/refs{/sha}","trees_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/statuses/{sha}","languages_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/languages","stargazers_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/stargazers","contributors_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/contributors","subscribers_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/subscribers","subscription_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/subscription","commits_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/commits{/sha}","git_commits_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/git/commits{/sha}","comments_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/comments{/number}","issue_comment_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/issues/comments{/number}","contents_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/contents/{+path}","compare_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/merges","archive_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/downloads","issues_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/issues{/number}","pulls_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls{/number}","milestones_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/milestones{/number}","notifications_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/labels{/name}","releases_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/releases{/id}","deployments_url":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/deployments","created_at":"2018-03-19T17:44:34Z","updated_at":"2018-08-21T01:12:46Z","pushed_at":"2018-08-21T01:12:50Z","git_url":"git://github.com/Sage-Bionetworks/mPower-2-Android.git","ssh_url":"git@github.com:Sage-Bionetworks/mPower-2-Android.git","clone_url":"https://github.com/Sage-Bionetworks/mPower-2-Android.git","svn_url":"https://github.com/Sage-Bionetworks/mPower-2-Android","homepage":null,"size":2740,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":7,"mirror_url":null,"archived":false,"open_issues_count":6,"license":{"key":"other","name":"Other","spdx_id":null,"url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":7,"open_issues":6,"watchers":0,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/33"},"html":{"href":"https://github.com/Sage-Bionetworks/mPower-2-Android/pull/33"},"issue":{"href":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/issues/33"},"comments":{"href":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/issues/33/comments"},"review_comments":{"href":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/33/comments"},"review_comment":{"href":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/pulls/33/commits"},"statuses":{"href":"https://api.github.com/repos/Sage-Bionetworks/mPower-2-Android/statuses/8f61813d0201cebeea44d9f6be4fe75e3b7b73e1"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"dephillipsmichael"}}