{"action":"created","comment":{"url":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/comments/76926256","id":76926256,"diff_hunk":"@@ -0,0 +1,36 @@\n+'use strict';\n+\n+/*\n+ * Prepare for mongodb connection to test.\n+ */\n+\n+let mongoose = require('mongoose');\n+\n+beforeEach(function (done) {\n+  function clearDB() {\n+    /*\n+     * This part is hided because it always cleanDB even when dev-mode,\n+     * so if test, dev DB separated, this would be added for test.\n+     */\n+    // for (var i in mongoose.connection.collections) {\n+    //   mongoose.connection.collections[i].remove(function() {});\n+    // }\n+    return done();\n+  }\n+  \n+  if (mongoose.connection.readyState === 0) {\n+    mongoose.connect('mongodb://localhost:27017/yoda', function (err) {\n+      if (err) {\n+        throw err;\n+      }\n+      return clearDB();\n+    });\n+  } else {","path":"src/test/utils.js","position":28,"original_position":28,"commit_id":"9bbc27c80a8ef61af3eb3c220adfc8988158b997","original_commit_id":"9bbc27c80a8ef61af3eb3c220adfc8988158b997","user":{"login":"fguy","id":1557628,"avatar_url":"https://avatars.githubusercontent.com/u/1557628?v=3","gravatar_id":"","url":"https://api.github.com/users/fguy","html_url":"https://github.com/fguy","followers_url":"https://api.github.com/users/fguy/followers","following_url":"https://api.github.com/users/fguy/following{/other_user}","gists_url":"https://api.github.com/users/fguy/gists{/gist_id}","starred_url":"https://api.github.com/users/fguy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fguy/subscriptions","organizations_url":"https://api.github.com/users/fguy/orgs","repos_url":"https://api.github.com/users/fguy/repos","events_url":"https://api.github.com/users/fguy/events{/privacy}","received_events_url":"https://api.github.com/users/fguy/received_events","type":"User","site_admin":false},"body":"You don't need else here.","created_at":"2016-08-31T05:23:29Z","updated_at":"2016-08-31T05:23:29Z","html_url":"https://github.com/sv-bootcamp/yoda/pull/21#discussion_r76926256","pull_request_url":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/21","_links":{"self":{"href":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/comments/76926256"},"html":{"href":"https://github.com/sv-bootcamp/yoda/pull/21#discussion_r76926256"},"pull_request":{"href":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/21"}}},"pull_request":{"url":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/21","id":83231881,"html_url":"https://github.com/sv-bootcamp/yoda/pull/21","diff_url":"https://github.com/sv-bootcamp/yoda/pull/21.diff","patch_url":"https://github.com/sv-bootcamp/yoda/pull/21.patch","issue_url":"https://api.github.com/repos/sv-bootcamp/yoda/issues/21","number":21,"state":"open","locked":false,"title":"ListView(getMentor) & Mocha setting","user":{"login":"SarahhhC","id":11007191,"avatar_url":"https://avatars.githubusercontent.com/u/11007191?v=3","gravatar_id":"","url":"https://api.github.com/users/SarahhhC","html_url":"https://github.com/SarahhhC","followers_url":"https://api.github.com/users/SarahhhC/followers","following_url":"https://api.github.com/users/SarahhhC/following{/other_user}","gists_url":"https://api.github.com/users/SarahhhC/gists{/gist_id}","starred_url":"https://api.github.com/users/SarahhhC/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SarahhhC/subscriptions","organizations_url":"https://api.github.com/users/SarahhhC/orgs","repos_url":"https://api.github.com/users/SarahhhC/repos","events_url":"https://api.github.com/users/SarahhhC/events{/privacy}","received_events_url":"https://api.github.com/users/SarahhhC/received_events","type":"User","site_admin":false},"body":"sprint for this Wednesday! Please comment me!\r\n\r\n@nlpenguin @ethkim @KaylaKwon @ifndefdeadmau5 @heartjigi ","created_at":"2016-08-30T08:54:11Z","updated_at":"2016-08-31T05:23:29Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a317a008aaa91aa028489bc47df56fe6ce616810","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/21/commits","review_comments_url":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/21/comments","review_comment_url":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/comments{/number}","comments_url":"https://api.github.com/repos/sv-bootcamp/yoda/issues/21/comments","statuses_url":"https://api.github.com/repos/sv-bootcamp/yoda/statuses/9bbc27c80a8ef61af3eb3c220adfc8988158b997","head":{"label":"sv-bootcamp:mocha","ref":"mocha","sha":"9bbc27c80a8ef61af3eb3c220adfc8988158b997","user":{"login":"sv-bootcamp","id":20648483,"avatar_url":"https://avatars.githubusercontent.com/u/20648483?v=3","gravatar_id":"","url":"https://api.github.com/users/sv-bootcamp","html_url":"https://github.com/sv-bootcamp","followers_url":"https://api.github.com/users/sv-bootcamp/followers","following_url":"https://api.github.com/users/sv-bootcamp/following{/other_user}","gists_url":"https://api.github.com/users/sv-bootcamp/gists{/gist_id}","starred_url":"https://api.github.com/users/sv-bootcamp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sv-bootcamp/subscriptions","organizations_url":"https://api.github.com/users/sv-bootcamp/orgs","repos_url":"https://api.github.com/users/sv-bootcamp/repos","events_url":"https://api.github.com/users/sv-bootcamp/events{/privacy}","received_events_url":"https://api.github.com/users/sv-bootcamp/received_events","type":"Organization","site_admin":false},"repo":{"id":65598569,"name":"yoda","full_name":"sv-bootcamp/yoda","owner":{"login":"sv-bootcamp","id":20648483,"avatar_url":"https://avatars.githubusercontent.com/u/20648483?v=3","gravatar_id":"","url":"https://api.github.com/users/sv-bootcamp","html_url":"https://github.com/sv-bootcamp","followers_url":"https://api.github.com/users/sv-bootcamp/followers","following_url":"https://api.github.com/users/sv-bootcamp/following{/other_user}","gists_url":"https://api.github.com/users/sv-bootcamp/gists{/gist_id}","starred_url":"https://api.github.com/users/sv-bootcamp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sv-bootcamp/subscriptions","organizations_url":"https://api.github.com/users/sv-bootcamp/orgs","repos_url":"https://api.github.com/users/sv-bootcamp/repos","events_url":"https://api.github.com/users/sv-bootcamp/events{/privacy}","received_events_url":"https://api.github.com/users/sv-bootcamp/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/sv-bootcamp/yoda","description":"Codename Yoda. Mentoring.","fork":false,"url":"https://api.github.com/repos/sv-bootcamp/yoda","forks_url":"https://api.github.com/repos/sv-bootcamp/yoda/forks","keys_url":"https://api.github.com/repos/sv-bootcamp/yoda/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sv-bootcamp/yoda/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sv-bootcamp/yoda/teams","hooks_url":"https://api.github.com/repos/sv-bootcamp/yoda/hooks","issue_events_url":"https://api.github.com/repos/sv-bootcamp/yoda/issues/events{/number}","events_url":"https://api.github.com/repos/sv-bootcamp/yoda/events","assignees_url":"https://api.github.com/repos/sv-bootcamp/yoda/assignees{/user}","branches_url":"https://api.github.com/repos/sv-bootcamp/yoda/branches{/branch}","tags_url":"https://api.github.com/repos/sv-bootcamp/yoda/tags","blobs_url":"https://api.github.com/repos/sv-bootcamp/yoda/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sv-bootcamp/yoda/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sv-bootcamp/yoda/git/refs{/sha}","trees_url":"https://api.github.com/repos/sv-bootcamp/yoda/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sv-bootcamp/yoda/statuses/{sha}","languages_url":"https://api.github.com/repos/sv-bootcamp/yoda/languages","stargazers_url":"https://api.github.com/repos/sv-bootcamp/yoda/stargazers","contributors_url":"https://api.github.com/repos/sv-bootcamp/yoda/contributors","subscribers_url":"https://api.github.com/repos/sv-bootcamp/yoda/subscribers","subscription_url":"https://api.github.com/repos/sv-bootcamp/yoda/subscription","commits_url":"https://api.github.com/repos/sv-bootcamp/yoda/commits{/sha}","git_commits_url":"https://api.github.com/repos/sv-bootcamp/yoda/git/commits{/sha}","comments_url":"https://api.github.com/repos/sv-bootcamp/yoda/comments{/number}","issue_comment_url":"https://api.github.com/repos/sv-bootcamp/yoda/issues/comments{/number}","contents_url":"https://api.github.com/repos/sv-bootcamp/yoda/contents/{+path}","compare_url":"https://api.github.com/repos/sv-bootcamp/yoda/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sv-bootcamp/yoda/merges","archive_url":"https://api.github.com/repos/sv-bootcamp/yoda/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sv-bootcamp/yoda/downloads","issues_url":"https://api.github.com/repos/sv-bootcamp/yoda/issues{/number}","pulls_url":"https://api.github.com/repos/sv-bootcamp/yoda/pulls{/number}","milestones_url":"https://api.github.com/repos/sv-bootcamp/yoda/milestones{/number}","notifications_url":"https://api.github.com/repos/sv-bootcamp/yoda/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sv-bootcamp/yoda/labels{/name}","releases_url":"https://api.github.com/repos/sv-bootcamp/yoda/releases{/id}","deployments_url":"https://api.github.com/repos/sv-bootcamp/yoda/deployments","created_at":"2016-08-13T04:09:04Z","updated_at":"2016-08-25T01:58:39Z","pushed_at":"2016-08-31T04:26:28Z","git_url":"git://github.com/sv-bootcamp/yoda.git","ssh_url":"git@github.com:sv-bootcamp/yoda.git","clone_url":"https://github.com/sv-bootcamp/yoda.git","svn_url":"https://github.com/sv-bootcamp/yoda","homepage":null,"size":23126,"stargazers_count":3,"watchers_count":3,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":3,"default_branch":"master"}},"base":{"label":"sv-bootcamp:master","ref":"master","sha":"2f2081cba5040a9d2c645988a6e7e725b929aaf5","user":{"login":"sv-bootcamp","id":20648483,"avatar_url":"https://avatars.githubusercontent.com/u/20648483?v=3","gravatar_id":"","url":"https://api.github.com/users/sv-bootcamp","html_url":"https://github.com/sv-bootcamp","followers_url":"https://api.github.com/users/sv-bootcamp/followers","following_url":"https://api.github.com/users/sv-bootcamp/following{/other_user}","gists_url":"https://api.github.com/users/sv-bootcamp/gists{/gist_id}","starred_url":"https://api.github.com/users/sv-bootcamp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sv-bootcamp/subscriptions","organizations_url":"https://api.github.com/users/sv-bootcamp/orgs","repos_url":"https://api.github.com/users/sv-bootcamp/repos","events_url":"https://api.github.com/users/sv-bootcamp/events{/privacy}","received_events_url":"https://api.github.com/users/sv-bootcamp/received_events","type":"Organization","site_admin":false},"repo":{"id":65598569,"name":"yoda","full_name":"sv-bootcamp/yoda","owner":{"login":"sv-bootcamp","id":20648483,"avatar_url":"https://avatars.githubusercontent.com/u/20648483?v=3","gravatar_id":"","url":"https://api.github.com/users/sv-bootcamp","html_url":"https://github.com/sv-bootcamp","followers_url":"https://api.github.com/users/sv-bootcamp/followers","following_url":"https://api.github.com/users/sv-bootcamp/following{/other_user}","gists_url":"https://api.github.com/users/sv-bootcamp/gists{/gist_id}","starred_url":"https://api.github.com/users/sv-bootcamp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sv-bootcamp/subscriptions","organizations_url":"https://api.github.com/users/sv-bootcamp/orgs","repos_url":"https://api.github.com/users/sv-bootcamp/repos","events_url":"https://api.github.com/users/sv-bootcamp/events{/privacy}","received_events_url":"https://api.github.com/users/sv-bootcamp/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/sv-bootcamp/yoda","description":"Codename Yoda. Mentoring.","fork":false,"url":"https://api.github.com/repos/sv-bootcamp/yoda","forks_url":"https://api.github.com/repos/sv-bootcamp/yoda/forks","keys_url":"https://api.github.com/repos/sv-bootcamp/yoda/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sv-bootcamp/yoda/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sv-bootcamp/yoda/teams","hooks_url":"https://api.github.com/repos/sv-bootcamp/yoda/hooks","issue_events_url":"https://api.github.com/repos/sv-bootcamp/yoda/issues/events{/number}","events_url":"https://api.github.com/repos/sv-bootcamp/yoda/events","assignees_url":"https://api.github.com/repos/sv-bootcamp/yoda/assignees{/user}","branches_url":"https://api.github.com/repos/sv-bootcamp/yoda/branches{/branch}","tags_url":"https://api.github.com/repos/sv-bootcamp/yoda/tags","blobs_url":"https://api.github.com/repos/sv-bootcamp/yoda/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sv-bootcamp/yoda/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sv-bootcamp/yoda/git/refs{/sha}","trees_url":"https://api.github.com/repos/sv-bootcamp/yoda/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sv-bootcamp/yoda/statuses/{sha}","languages_url":"https://api.github.com/repos/sv-bootcamp/yoda/languages","stargazers_url":"https://api.github.com/repos/sv-bootcamp/yoda/stargazers","contributors_url":"https://api.github.com/repos/sv-bootcamp/yoda/contributors","subscribers_url":"https://api.github.com/repos/sv-bootcamp/yoda/subscribers","subscription_url":"https://api.github.com/repos/sv-bootcamp/yoda/subscription","commits_url":"https://api.github.com/repos/sv-bootcamp/yoda/commits{/sha}","git_commits_url":"https://api.github.com/repos/sv-bootcamp/yoda/git/commits{/sha}","comments_url":"https://api.github.com/repos/sv-bootcamp/yoda/comments{/number}","issue_comment_url":"https://api.github.com/repos/sv-bootcamp/yoda/issues/comments{/number}","contents_url":"https://api.github.com/repos/sv-bootcamp/yoda/contents/{+path}","compare_url":"https://api.github.com/repos/sv-bootcamp/yoda/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sv-bootcamp/yoda/merges","archive_url":"https://api.github.com/repos/sv-bootcamp/yoda/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sv-bootcamp/yoda/downloads","issues_url":"https://api.github.com/repos/sv-bootcamp/yoda/issues{/number}","pulls_url":"https://api.github.com/repos/sv-bootcamp/yoda/pulls{/number}","milestones_url":"https://api.github.com/repos/sv-bootcamp/yoda/milestones{/number}","notifications_url":"https://api.github.com/repos/sv-bootcamp/yoda/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sv-bootcamp/yoda/labels{/name}","releases_url":"https://api.github.com/repos/sv-bootcamp/yoda/releases{/id}","deployments_url":"https://api.github.com/repos/sv-bootcamp/yoda/deployments","created_at":"2016-08-13T04:09:04Z","updated_at":"2016-08-25T01:58:39Z","pushed_at":"2016-08-31T04:26:28Z","git_url":"git://github.com/sv-bootcamp/yoda.git","ssh_url":"git@github.com:sv-bootcamp/yoda.git","clone_url":"https://github.com/sv-bootcamp/yoda.git","svn_url":"https://github.com/sv-bootcamp/yoda","homepage":null,"size":23126,"stargazers_count":3,"watchers_count":3,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":3,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/21"},"html":{"href":"https://github.com/sv-bootcamp/yoda/pull/21"},"issue":{"href":"https://api.github.com/repos/sv-bootcamp/yoda/issues/21"},"comments":{"href":"https://api.github.com/repos/sv-bootcamp/yoda/issues/21/comments"},"review_comments":{"href":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/21/comments"},"review_comment":{"href":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/sv-bootcamp/yoda/pulls/21/commits"},"statuses":{"href":"https://api.github.com/repos/sv-bootcamp/yoda/statuses/9bbc27c80a8ef61af3eb3c220adfc8988158b997"}}}}
{"actor":{"display_login":"fguy"}}