{"action":"created","comment":{"url":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/comments/174534608","pull_request_review_id":103909611,"id":174534608,"diff_hunk":"@@ -210,22 +212,63 @@ def test_message_all_members_false_projectmemberid_has_invalid_char(self):\n         response = message(project_member_ids=['abcdef1', 'test'],\n                            subject=SUBJECT, message=MESSAGE,\n                            access_token=MASTER_ACCESS_TOKEN)\n-        assert response.json() == {\"errors\": {\"project_member_ids\":\n-                                   [\"Project member IDs are always 8\" +\n-                                    \" digits long.\"]}}\n+        assert response.json() == {\"errors\":\n+                                   {\"project_member_ids\":\n+                                    [\"Project member IDs are always 8\" +\n+                                     \" digits long.\"]}}\n \n     @my_vcr.use_cassette()\n     def test_message_all_members_false_projectmemberid_has_invalid_digit(self):\n         response = message(project_member_ids=[INVALID_PMI1, INVALID_PMI2],\n                            subject=SUBJECT, message=MESSAGE,\n                            access_token=MASTER_ACCESS_TOKEN)\n-        assert response.json() == {\"errors\": {\"project_member_ids\":\n-                                   [\"Invalid project member ID(s):\" +\n-                                    \" invalidPMI2\"]}}\n+        assert response.json() == {\"errors\":\n+                                   {\"project_member_ids\":\n+                                    [\"Invalid project member ID(s):\" +\n+                                     \" invalidPMI2\"]}}\n \n     @my_vcr.use_cassette()\n     def test_message_all_members_false_project_member_id_not_none_valid(self):\n         response = message(project_member_ids=[VALID_PMI1, VALID_PMI2],\n                            subject=SUBJECT, message=MESSAGE,\n                            access_token=ACCESS_TOKEN)\n         self.assertEqual(response.status_code, 200)\n+\n+\n+class APITestDeleteFile(TestCase):\n+\n+    def setUp(self):\n+        pass\n+\n+    @my_vcr.use_cassette()\n+    def test_delete_file__invalid_access_token(self):\n+        response = delete_file(\n+            access_token=ACCESS_TOKEN_INVALID, project_member_id='59319749',\n+            all_files=True)\n+        assert response.json() == {\"detail\": \"Invalid token.\"}\n+\n+    @my_vcr.use_cassette()\n+    def test_delete_file_project_member_id_given(self):\n+        response = delete_file(access_token=ACCESS_TOKEN,\n+                               project_member_id='59319749', all_files=True)\n+        self.assertEqual(response.status_code, 200)\n+\n+    @my_vcr.use_cassette()\n+    def test_delete_file_project_member_id_invalid(self):\n+        response = delete_file(access_token=ACCESS_TOKEN, all_files=True,\n+                               project_member_id='1234')\n+        self.assertEqual(response.status_code, 400)\n+\n+    @my_vcr.use_cassette()\n+    def test_delete_file__expired_access_token(self):\n+        response = delete_file(access_token=ACCESS_TOKEN_EXPIRED,","path":"ohapi/tests/test_api.py","position":95,"original_position":95,"commit_id":"8b0791bbd0a6cd72bba6b1e20e285efc95da6df0","original_commit_id":"8b0791bbd0a6cd72bba6b1e20e285efc95da6df0","user":{"login":"houndci-bot","id":6697940,"avatar_url":"https://avatars0.githubusercontent.com/u/6697940?v=4","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":"undefined name 'ACCESS_TOKEN_EXPIRED'","created_at":"2018-03-14T17:00:55Z","updated_at":"2018-03-14T17:00:56Z","html_url":"https://github.com/OpenHumans/open-humans-api/pull/39#discussion_r174534608","pull_request_url":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/39","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/comments/174534608"},"html":{"href":"https://github.com/OpenHumans/open-humans-api/pull/39#discussion_r174534608"},"pull_request":{"href":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/39"}}},"pull_request":{"url":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/39","id":174246688,"html_url":"https://github.com/OpenHumans/open-humans-api/pull/39","diff_url":"https://github.com/OpenHumans/open-humans-api/pull/39.diff","patch_url":"https://github.com/OpenHumans/open-humans-api/pull/39.patch","issue_url":"https://api.github.com/repos/OpenHumans/open-humans-api/issues/39","number":39,"state":"open","locked":false,"title":"[WIP] add tests for  delete file","user":{"login":"kritisingh1","id":22004158,"avatar_url":"https://avatars2.githubusercontent.com/u/22004158?v=4","gravatar_id":"","url":"https://api.github.com/users/kritisingh1","html_url":"https://github.com/kritisingh1","followers_url":"https://api.github.com/users/kritisingh1/followers","following_url":"https://api.github.com/users/kritisingh1/following{/other_user}","gists_url":"https://api.github.com/users/kritisingh1/gists{/gist_id}","starred_url":"https://api.github.com/users/kritisingh1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kritisingh1/subscriptions","organizations_url":"https://api.github.com/users/kritisingh1/orgs","repos_url":"https://api.github.com/users/kritisingh1/repos","events_url":"https://api.github.com/users/kritisingh1/events{/privacy}","received_events_url":"https://api.github.com/users/kritisingh1/received_events","type":"User","site_admin":false},"body":"<!--- Provide a general summary of your changes in the Title above -->\r\n\r\n## General Checkups\r\n- [x] Have you checked that there aren't other open pull requests for the same issue/update/change?\r\n- [x] If your code includes new features and not just bug fixes/copy editing: Did you include new tests?\r\n\r\n<!---\r\nby the way: if you want to discuss feature requests and bugs with us before submitting anything on GitHub: We're always happy to chat on Slack: http://slackin.openhumans.org/\r\n -->\r\n\r\n## Description\r\n<!--- Describe your changes in detail -->\r\nAdd tests for `delete_file` in `ohapi/api.py`\r\n\r\n## Related Issue\r\n<!--- if this closes an issue make sure include e.g., \"fix #4\"\r\nor similar - or if just relates to an issue make sure to mention\r\nit like \"#4\" -->\r\nAddresses one of the points of #14\r\n\r\n## Example\r\n<!--- if introducing a new feature or changing behavior of existing\r\nmethods/functions, include an example if possible to do in brief form -->\r\n\r\n<!--- Did you remember to include tests? Unless you're just changing\r\ngrammar, please include new tests for your change -->\r\n","created_at":"2018-03-11T22:36:13Z","updated_at":"2018-03-14T17:00:56Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3dd8cc71e06332341aa49b66057f70885ce39cae","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/39/commits","review_comments_url":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/39/comments","review_comment_url":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/comments{/number}","comments_url":"https://api.github.com/repos/OpenHumans/open-humans-api/issues/39/comments","statuses_url":"https://api.github.com/repos/OpenHumans/open-humans-api/statuses/8b0791bbd0a6cd72bba6b1e20e285efc95da6df0","head":{"label":"kritisingh1:api-test","ref":"api-test","sha":"8b0791bbd0a6cd72bba6b1e20e285efc95da6df0","user":{"login":"kritisingh1","id":22004158,"avatar_url":"https://avatars2.githubusercontent.com/u/22004158?v=4","gravatar_id":"","url":"https://api.github.com/users/kritisingh1","html_url":"https://github.com/kritisingh1","followers_url":"https://api.github.com/users/kritisingh1/followers","following_url":"https://api.github.com/users/kritisingh1/following{/other_user}","gists_url":"https://api.github.com/users/kritisingh1/gists{/gist_id}","starred_url":"https://api.github.com/users/kritisingh1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kritisingh1/subscriptions","organizations_url":"https://api.github.com/users/kritisingh1/orgs","repos_url":"https://api.github.com/users/kritisingh1/repos","events_url":"https://api.github.com/users/kritisingh1/events{/privacy}","received_events_url":"https://api.github.com/users/kritisingh1/received_events","type":"User","site_admin":false},"repo":{"id":122904035,"name":"open-humans-api","full_name":"kritisingh1/open-humans-api","owner":{"login":"kritisingh1","id":22004158,"avatar_url":"https://avatars2.githubusercontent.com/u/22004158?v=4","gravatar_id":"","url":"https://api.github.com/users/kritisingh1","html_url":"https://github.com/kritisingh1","followers_url":"https://api.github.com/users/kritisingh1/followers","following_url":"https://api.github.com/users/kritisingh1/following{/other_user}","gists_url":"https://api.github.com/users/kritisingh1/gists{/gist_id}","starred_url":"https://api.github.com/users/kritisingh1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kritisingh1/subscriptions","organizations_url":"https://api.github.com/users/kritisingh1/orgs","repos_url":"https://api.github.com/users/kritisingh1/repos","events_url":"https://api.github.com/users/kritisingh1/events{/privacy}","received_events_url":"https://api.github.com/users/kritisingh1/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/kritisingh1/open-humans-api","description":"Tools to work with our APIs.","fork":true,"url":"https://api.github.com/repos/kritisingh1/open-humans-api","forks_url":"https://api.github.com/repos/kritisingh1/open-humans-api/forks","keys_url":"https://api.github.com/repos/kritisingh1/open-humans-api/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kritisingh1/open-humans-api/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kritisingh1/open-humans-api/teams","hooks_url":"https://api.github.com/repos/kritisingh1/open-humans-api/hooks","issue_events_url":"https://api.github.com/repos/kritisingh1/open-humans-api/issues/events{/number}","events_url":"https://api.github.com/repos/kritisingh1/open-humans-api/events","assignees_url":"https://api.github.com/repos/kritisingh1/open-humans-api/assignees{/user}","branches_url":"https://api.github.com/repos/kritisingh1/open-humans-api/branches{/branch}","tags_url":"https://api.github.com/repos/kritisingh1/open-humans-api/tags","blobs_url":"https://api.github.com/repos/kritisingh1/open-humans-api/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kritisingh1/open-humans-api/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kritisingh1/open-humans-api/git/refs{/sha}","trees_url":"https://api.github.com/repos/kritisingh1/open-humans-api/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kritisingh1/open-humans-api/statuses/{sha}","languages_url":"https://api.github.com/repos/kritisingh1/open-humans-api/languages","stargazers_url":"https://api.github.com/repos/kritisingh1/open-humans-api/stargazers","contributors_url":"https://api.github.com/repos/kritisingh1/open-humans-api/contributors","subscribers_url":"https://api.github.com/repos/kritisingh1/open-humans-api/subscribers","subscription_url":"https://api.github.com/repos/kritisingh1/open-humans-api/subscription","commits_url":"https://api.github.com/repos/kritisingh1/open-humans-api/commits{/sha}","git_commits_url":"https://api.github.com/repos/kritisingh1/open-humans-api/git/commits{/sha}","comments_url":"https://api.github.com/repos/kritisingh1/open-humans-api/comments{/number}","issue_comment_url":"https://api.github.com/repos/kritisingh1/open-humans-api/issues/comments{/number}","contents_url":"https://api.github.com/repos/kritisingh1/open-humans-api/contents/{+path}","compare_url":"https://api.github.com/repos/kritisingh1/open-humans-api/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kritisingh1/open-humans-api/merges","archive_url":"https://api.github.com/repos/kritisingh1/open-humans-api/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kritisingh1/open-humans-api/downloads","issues_url":"https://api.github.com/repos/kritisingh1/open-humans-api/issues{/number}","pulls_url":"https://api.github.com/repos/kritisingh1/open-humans-api/pulls{/number}","milestones_url":"https://api.github.com/repos/kritisingh1/open-humans-api/milestones{/number}","notifications_url":"https://api.github.com/repos/kritisingh1/open-humans-api/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kritisingh1/open-humans-api/labels{/name}","releases_url":"https://api.github.com/repos/kritisingh1/open-humans-api/releases{/id}","deployments_url":"https://api.github.com/repos/kritisingh1/open-humans-api/deployments","created_at":"2018-02-26T02:53:00Z","updated_at":"2018-02-26T02:53:02Z","pushed_at":"2018-03-14T17:00:41Z","git_url":"git://github.com/kritisingh1/open-humans-api.git","ssh_url":"git@github.com:kritisingh1/open-humans-api.git","clone_url":"https://github.com/kritisingh1/open-humans-api.git","svn_url":"https://github.com/kritisingh1/open-humans-api","homepage":null,"size":102,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":1,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"OpenHumans:master","ref":"master","sha":"ae3943f413a619a03687c06ecd1637646ff9221d","user":{"login":"OpenHumans","id":3341265,"avatar_url":"https://avatars3.githubusercontent.com/u/3341265?v=4","gravatar_id":"","url":"https://api.github.com/users/OpenHumans","html_url":"https://github.com/OpenHumans","followers_url":"https://api.github.com/users/OpenHumans/followers","following_url":"https://api.github.com/users/OpenHumans/following{/other_user}","gists_url":"https://api.github.com/users/OpenHumans/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenHumans/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenHumans/subscriptions","organizations_url":"https://api.github.com/users/OpenHumans/orgs","repos_url":"https://api.github.com/users/OpenHumans/repos","events_url":"https://api.github.com/users/OpenHumans/events{/privacy}","received_events_url":"https://api.github.com/users/OpenHumans/received_events","type":"Organization","site_admin":false},"repo":{"id":65763791,"name":"open-humans-api","full_name":"OpenHumans/open-humans-api","owner":{"login":"OpenHumans","id":3341265,"avatar_url":"https://avatars3.githubusercontent.com/u/3341265?v=4","gravatar_id":"","url":"https://api.github.com/users/OpenHumans","html_url":"https://github.com/OpenHumans","followers_url":"https://api.github.com/users/OpenHumans/followers","following_url":"https://api.github.com/users/OpenHumans/following{/other_user}","gists_url":"https://api.github.com/users/OpenHumans/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenHumans/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenHumans/subscriptions","organizations_url":"https://api.github.com/users/OpenHumans/orgs","repos_url":"https://api.github.com/users/OpenHumans/repos","events_url":"https://api.github.com/users/OpenHumans/events{/privacy}","received_events_url":"https://api.github.com/users/OpenHumans/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/OpenHumans/open-humans-api","description":"Tools to work with our APIs.","fork":false,"url":"https://api.github.com/repos/OpenHumans/open-humans-api","forks_url":"https://api.github.com/repos/OpenHumans/open-humans-api/forks","keys_url":"https://api.github.com/repos/OpenHumans/open-humans-api/keys{/key_id}","collaborators_url":"https://api.github.com/repos/OpenHumans/open-humans-api/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/OpenHumans/open-humans-api/teams","hooks_url":"https://api.github.com/repos/OpenHumans/open-humans-api/hooks","issue_events_url":"https://api.github.com/repos/OpenHumans/open-humans-api/issues/events{/number}","events_url":"https://api.github.com/repos/OpenHumans/open-humans-api/events","assignees_url":"https://api.github.com/repos/OpenHumans/open-humans-api/assignees{/user}","branches_url":"https://api.github.com/repos/OpenHumans/open-humans-api/branches{/branch}","tags_url":"https://api.github.com/repos/OpenHumans/open-humans-api/tags","blobs_url":"https://api.github.com/repos/OpenHumans/open-humans-api/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/OpenHumans/open-humans-api/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/OpenHumans/open-humans-api/git/refs{/sha}","trees_url":"https://api.github.com/repos/OpenHumans/open-humans-api/git/trees{/sha}","statuses_url":"https://api.github.com/repos/OpenHumans/open-humans-api/statuses/{sha}","languages_url":"https://api.github.com/repos/OpenHumans/open-humans-api/languages","stargazers_url":"https://api.github.com/repos/OpenHumans/open-humans-api/stargazers","contributors_url":"https://api.github.com/repos/OpenHumans/open-humans-api/contributors","subscribers_url":"https://api.github.com/repos/OpenHumans/open-humans-api/subscribers","subscription_url":"https://api.github.com/repos/OpenHumans/open-humans-api/subscription","commits_url":"https://api.github.com/repos/OpenHumans/open-humans-api/commits{/sha}","git_commits_url":"https://api.github.com/repos/OpenHumans/open-humans-api/git/commits{/sha}","comments_url":"https://api.github.com/repos/OpenHumans/open-humans-api/comments{/number}","issue_comment_url":"https://api.github.com/repos/OpenHumans/open-humans-api/issues/comments{/number}","contents_url":"https://api.github.com/repos/OpenHumans/open-humans-api/contents/{+path}","compare_url":"https://api.github.com/repos/OpenHumans/open-humans-api/compare/{base}...{head}","merges_url":"https://api.github.com/repos/OpenHumans/open-humans-api/merges","archive_url":"https://api.github.com/repos/OpenHumans/open-humans-api/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/OpenHumans/open-humans-api/downloads","issues_url":"https://api.github.com/repos/OpenHumans/open-humans-api/issues{/number}","pulls_url":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls{/number}","milestones_url":"https://api.github.com/repos/OpenHumans/open-humans-api/milestones{/number}","notifications_url":"https://api.github.com/repos/OpenHumans/open-humans-api/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/OpenHumans/open-humans-api/labels{/name}","releases_url":"https://api.github.com/repos/OpenHumans/open-humans-api/releases{/id}","deployments_url":"https://api.github.com/repos/OpenHumans/open-humans-api/deployments","created_at":"2016-08-15T20:44:53Z","updated_at":"2018-03-12T08:18:00Z","pushed_at":"2018-03-14T17:00:43Z","git_url":"git://github.com/OpenHumans/open-humans-api.git","ssh_url":"git@github.com:OpenHumans/open-humans-api.git","clone_url":"https://github.com/OpenHumans/open-humans-api.git","svn_url":"https://github.com/OpenHumans/open-humans-api","homepage":null,"size":61,"stargazers_count":6,"watchers_count":6,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":11,"mirror_url":null,"archived":false,"open_issues_count":9,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":11,"open_issues":9,"watchers":6,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/39"},"html":{"href":"https://github.com/OpenHumans/open-humans-api/pull/39"},"issue":{"href":"https://api.github.com/repos/OpenHumans/open-humans-api/issues/39"},"comments":{"href":"https://api.github.com/repos/OpenHumans/open-humans-api/issues/39/comments"},"review_comments":{"href":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/39/comments"},"review_comment":{"href":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/OpenHumans/open-humans-api/pulls/39/commits"},"statuses":{"href":"https://api.github.com/repos/OpenHumans/open-humans-api/statuses/8b0791bbd0a6cd72bba6b1e20e285efc95da6df0"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"houndci-bot"}}