{"action":"created","comment":{"url":"https://api.github.com/repos/Flolagale/mailin/pulls/comments/48436008","id":48436008,"diff_hunk":"@@ -16,15 +16,34 @@ chai.use(chaiAsPromised);\n var should = null;\n should = chai.Should();\n \n+var server = express(),","path":"test/mailinSpec.js","position":4,"original_position":4,"commit_id":"1bb73503d6f83c819fe1b45fd516e9f77ae1b02c","original_commit_id":"1bb73503d6f83c819fe1b45fd516e9f77ae1b02c","user":{"login":"mefernandez","id":845346,"avatar_url":"https://avatars.githubusercontent.com/u/845346?v=3","gravatar_id":"","url":"https://api.github.com/users/mefernandez","html_url":"https://github.com/mefernandez","followers_url":"https://api.github.com/users/mefernandez/followers","following_url":"https://api.github.com/users/mefernandez/following{/other_user}","gists_url":"https://api.github.com/users/mefernandez/gists{/gist_id}","starred_url":"https://api.github.com/users/mefernandez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mefernandez/subscriptions","organizations_url":"https://api.github.com/users/mefernandez/orgs","repos_url":"https://api.github.com/users/mefernandez/repos","events_url":"https://api.github.com/users/mefernandez/events{/privacy}","received_events_url":"https://api.github.com/users/mefernandez/received_events","type":"User","site_admin":false},"body":"I had to move this up here, to make it listen before `Mailin.start()` gets called and checks `/webhook`.","created_at":"2015-12-25T08:49:23Z","updated_at":"2015-12-25T08:49:23Z","html_url":"https://github.com/Flolagale/mailin/pull/74#discussion_r48436008","pull_request_url":"https://api.github.com/repos/Flolagale/mailin/pulls/74","_links":{"self":{"href":"https://api.github.com/repos/Flolagale/mailin/pulls/comments/48436008"},"html":{"href":"https://github.com/Flolagale/mailin/pull/74#discussion_r48436008"},"pull_request":{"href":"https://api.github.com/repos/Flolagale/mailin/pulls/74"}}},"pull_request":{"url":"https://api.github.com/repos/Flolagale/mailin/pulls/74","id":54580292,"html_url":"https://github.com/Flolagale/mailin/pull/74","diff_url":"https://github.com/Flolagale/mailin/pull/74.diff","patch_url":"https://github.com/Flolagale/mailin/pull/74.patch","issue_url":"https://api.github.com/repos/Flolagale/mailin/issues/74","number":74,"state":"open","locked":false,"title":"Closes #72, fixed supertest's request.head() webhook check invocation","user":{"login":"mefernandez","id":845346,"avatar_url":"https://avatars.githubusercontent.com/u/845346?v=3","gravatar_id":"","url":"https://api.github.com/users/mefernandez","html_url":"https://github.com/mefernandez","followers_url":"https://api.github.com/users/mefernandez/followers","following_url":"https://api.github.com/users/mefernandez/following{/other_user}","gists_url":"https://api.github.com/users/mefernandez/gists{/gist_id}","starred_url":"https://api.github.com/users/mefernandez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mefernandez/subscriptions","organizations_url":"https://api.github.com/users/mefernandez/orgs","repos_url":"https://api.github.com/users/mefernandez/repos","events_url":"https://api.github.com/users/mefernandez/events{/privacy}","received_events_url":"https://api.github.com/users/mefernandez/received_events","type":"User","site_admin":false},"body":"Just 2 things in this PR:\r\n1. A simple fix to supertest's `req.head()` call\r\n2. Some changes in `test/mailinSpec.js` to check it's working.\r\n\r\nItem 1 is a no-brainer, but item 2 should arise some discussion. From my point of view, the specs are mixing unit and integration tests, which makes testing very difficult. I'm not happy with the way I changed `mailinSpec.js` at all, but I couldn't find a more simple and elegant solution. Do you see any other way to do it?\r\n","created_at":"2015-12-25T08:47:49Z","updated_at":"2015-12-25T08:49:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7a9e0dc6b5df2849b8d88b5a3e1a9ce2937a8be8","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Flolagale/mailin/pulls/74/commits","review_comments_url":"https://api.github.com/repos/Flolagale/mailin/pulls/74/comments","review_comment_url":"https://api.github.com/repos/Flolagale/mailin/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Flolagale/mailin/issues/74/comments","statuses_url":"https://api.github.com/repos/Flolagale/mailin/statuses/1bb73503d6f83c819fe1b45fd516e9f77ae1b02c","head":{"label":"mefernandez:issue-72","ref":"issue-72","sha":"1bb73503d6f83c819fe1b45fd516e9f77ae1b02c","user":{"login":"mefernandez","id":845346,"avatar_url":"https://avatars.githubusercontent.com/u/845346?v=3","gravatar_id":"","url":"https://api.github.com/users/mefernandez","html_url":"https://github.com/mefernandez","followers_url":"https://api.github.com/users/mefernandez/followers","following_url":"https://api.github.com/users/mefernandez/following{/other_user}","gists_url":"https://api.github.com/users/mefernandez/gists{/gist_id}","starred_url":"https://api.github.com/users/mefernandez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mefernandez/subscriptions","organizations_url":"https://api.github.com/users/mefernandez/orgs","repos_url":"https://api.github.com/users/mefernandez/repos","events_url":"https://api.github.com/users/mefernandez/events{/privacy}","received_events_url":"https://api.github.com/users/mefernandez/received_events","type":"User","site_admin":false},"repo":{"id":48040937,"name":"mailin","full_name":"mefernandez/mailin","owner":{"login":"mefernandez","id":845346,"avatar_url":"https://avatars.githubusercontent.com/u/845346?v=3","gravatar_id":"","url":"https://api.github.com/users/mefernandez","html_url":"https://github.com/mefernandez","followers_url":"https://api.github.com/users/mefernandez/followers","following_url":"https://api.github.com/users/mefernandez/following{/other_user}","gists_url":"https://api.github.com/users/mefernandez/gists{/gist_id}","starred_url":"https://api.github.com/users/mefernandez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mefernandez/subscriptions","organizations_url":"https://api.github.com/users/mefernandez/orgs","repos_url":"https://api.github.com/users/mefernandez/repos","events_url":"https://api.github.com/users/mefernandez/events{/privacy}","received_events_url":"https://api.github.com/users/mefernandez/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mefernandez/mailin","description":"Artisanal inbound emails for every web app","fork":true,"url":"https://api.github.com/repos/mefernandez/mailin","forks_url":"https://api.github.com/repos/mefernandez/mailin/forks","keys_url":"https://api.github.com/repos/mefernandez/mailin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mefernandez/mailin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mefernandez/mailin/teams","hooks_url":"https://api.github.com/repos/mefernandez/mailin/hooks","issue_events_url":"https://api.github.com/repos/mefernandez/mailin/issues/events{/number}","events_url":"https://api.github.com/repos/mefernandez/mailin/events","assignees_url":"https://api.github.com/repos/mefernandez/mailin/assignees{/user}","branches_url":"https://api.github.com/repos/mefernandez/mailin/branches{/branch}","tags_url":"https://api.github.com/repos/mefernandez/mailin/tags","blobs_url":"https://api.github.com/repos/mefernandez/mailin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mefernandez/mailin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mefernandez/mailin/git/refs{/sha}","trees_url":"https://api.github.com/repos/mefernandez/mailin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mefernandez/mailin/statuses/{sha}","languages_url":"https://api.github.com/repos/mefernandez/mailin/languages","stargazers_url":"https://api.github.com/repos/mefernandez/mailin/stargazers","contributors_url":"https://api.github.com/repos/mefernandez/mailin/contributors","subscribers_url":"https://api.github.com/repos/mefernandez/mailin/subscribers","subscription_url":"https://api.github.com/repos/mefernandez/mailin/subscription","commits_url":"https://api.github.com/repos/mefernandez/mailin/commits{/sha}","git_commits_url":"https://api.github.com/repos/mefernandez/mailin/git/commits{/sha}","comments_url":"https://api.github.com/repos/mefernandez/mailin/comments{/number}","issue_comment_url":"https://api.github.com/repos/mefernandez/mailin/issues/comments{/number}","contents_url":"https://api.github.com/repos/mefernandez/mailin/contents/{+path}","compare_url":"https://api.github.com/repos/mefernandez/mailin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mefernandez/mailin/merges","archive_url":"https://api.github.com/repos/mefernandez/mailin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mefernandez/mailin/downloads","issues_url":"https://api.github.com/repos/mefernandez/mailin/issues{/number}","pulls_url":"https://api.github.com/repos/mefernandez/mailin/pulls{/number}","milestones_url":"https://api.github.com/repos/mefernandez/mailin/milestones{/number}","notifications_url":"https://api.github.com/repos/mefernandez/mailin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mefernandez/mailin/labels{/name}","releases_url":"https://api.github.com/repos/mefernandez/mailin/releases{/id}","created_at":"2015-12-15T12:17:04Z","updated_at":"2015-12-15T12:17:05Z","pushed_at":"2015-12-25T08:40:25Z","git_url":"git://github.com/mefernandez/mailin.git","ssh_url":"git@github.com:mefernandez/mailin.git","clone_url":"https://github.com/mefernandez/mailin.git","svn_url":"https://github.com/mefernandez/mailin","homepage":"mailin.io","size":596,"stargazers_count":0,"watchers_count":0,"language":"Python","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":"Flolagale:master","ref":"master","sha":"f0571f16ced39c6ddaa42272f8fcc125b8743bf8","user":{"login":"Flolagale","id":1089942,"avatar_url":"https://avatars.githubusercontent.com/u/1089942?v=3","gravatar_id":"","url":"https://api.github.com/users/Flolagale","html_url":"https://github.com/Flolagale","followers_url":"https://api.github.com/users/Flolagale/followers","following_url":"https://api.github.com/users/Flolagale/following{/other_user}","gists_url":"https://api.github.com/users/Flolagale/gists{/gist_id}","starred_url":"https://api.github.com/users/Flolagale/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Flolagale/subscriptions","organizations_url":"https://api.github.com/users/Flolagale/orgs","repos_url":"https://api.github.com/users/Flolagale/repos","events_url":"https://api.github.com/users/Flolagale/events{/privacy}","received_events_url":"https://api.github.com/users/Flolagale/received_events","type":"User","site_admin":false},"repo":{"id":17950486,"name":"mailin","full_name":"Flolagale/mailin","owner":{"login":"Flolagale","id":1089942,"avatar_url":"https://avatars.githubusercontent.com/u/1089942?v=3","gravatar_id":"","url":"https://api.github.com/users/Flolagale","html_url":"https://github.com/Flolagale","followers_url":"https://api.github.com/users/Flolagale/followers","following_url":"https://api.github.com/users/Flolagale/following{/other_user}","gists_url":"https://api.github.com/users/Flolagale/gists{/gist_id}","starred_url":"https://api.github.com/users/Flolagale/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Flolagale/subscriptions","organizations_url":"https://api.github.com/users/Flolagale/orgs","repos_url":"https://api.github.com/users/Flolagale/repos","events_url":"https://api.github.com/users/Flolagale/events{/privacy}","received_events_url":"https://api.github.com/users/Flolagale/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Flolagale/mailin","description":"Artisanal inbound emails for every web app","fork":false,"url":"https://api.github.com/repos/Flolagale/mailin","forks_url":"https://api.github.com/repos/Flolagale/mailin/forks","keys_url":"https://api.github.com/repos/Flolagale/mailin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Flolagale/mailin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Flolagale/mailin/teams","hooks_url":"https://api.github.com/repos/Flolagale/mailin/hooks","issue_events_url":"https://api.github.com/repos/Flolagale/mailin/issues/events{/number}","events_url":"https://api.github.com/repos/Flolagale/mailin/events","assignees_url":"https://api.github.com/repos/Flolagale/mailin/assignees{/user}","branches_url":"https://api.github.com/repos/Flolagale/mailin/branches{/branch}","tags_url":"https://api.github.com/repos/Flolagale/mailin/tags","blobs_url":"https://api.github.com/repos/Flolagale/mailin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Flolagale/mailin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Flolagale/mailin/git/refs{/sha}","trees_url":"https://api.github.com/repos/Flolagale/mailin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Flolagale/mailin/statuses/{sha}","languages_url":"https://api.github.com/repos/Flolagale/mailin/languages","stargazers_url":"https://api.github.com/repos/Flolagale/mailin/stargazers","contributors_url":"https://api.github.com/repos/Flolagale/mailin/contributors","subscribers_url":"https://api.github.com/repos/Flolagale/mailin/subscribers","subscription_url":"https://api.github.com/repos/Flolagale/mailin/subscription","commits_url":"https://api.github.com/repos/Flolagale/mailin/commits{/sha}","git_commits_url":"https://api.github.com/repos/Flolagale/mailin/git/commits{/sha}","comments_url":"https://api.github.com/repos/Flolagale/mailin/comments{/number}","issue_comment_url":"https://api.github.com/repos/Flolagale/mailin/issues/comments{/number}","contents_url":"https://api.github.com/repos/Flolagale/mailin/contents/{+path}","compare_url":"https://api.github.com/repos/Flolagale/mailin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Flolagale/mailin/merges","archive_url":"https://api.github.com/repos/Flolagale/mailin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Flolagale/mailin/downloads","issues_url":"https://api.github.com/repos/Flolagale/mailin/issues{/number}","pulls_url":"https://api.github.com/repos/Flolagale/mailin/pulls{/number}","milestones_url":"https://api.github.com/repos/Flolagale/mailin/milestones{/number}","notifications_url":"https://api.github.com/repos/Flolagale/mailin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Flolagale/mailin/labels{/name}","releases_url":"https://api.github.com/repos/Flolagale/mailin/releases{/id}","created_at":"2014-03-20T16:49:11Z","updated_at":"2015-12-23T15:01:02Z","pushed_at":"2015-12-25T08:47:49Z","git_url":"git://github.com/Flolagale/mailin.git","ssh_url":"git@github.com:Flolagale/mailin.git","clone_url":"https://github.com/Flolagale/mailin.git","svn_url":"https://github.com/Flolagale/mailin","homepage":"mailin.io","size":644,"stargazers_count":1338,"watchers_count":1338,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":72,"mirror_url":null,"open_issues_count":22,"forks":72,"open_issues":22,"watchers":1338,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Flolagale/mailin/pulls/74"},"html":{"href":"https://github.com/Flolagale/mailin/pull/74"},"issue":{"href":"https://api.github.com/repos/Flolagale/mailin/issues/74"},"comments":{"href":"https://api.github.com/repos/Flolagale/mailin/issues/74/comments"},"review_comments":{"href":"https://api.github.com/repos/Flolagale/mailin/pulls/74/comments"},"review_comment":{"href":"https://api.github.com/repos/Flolagale/mailin/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Flolagale/mailin/pulls/74/commits"},"statuses":{"href":"https://api.github.com/repos/Flolagale/mailin/statuses/1bb73503d6f83c819fe1b45fd516e9f77ae1b02c"}}}}