{"action":"created","comment":{"url":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/comments/48688096","id":48688096,"diff_hunk":"@@ -0,0 +1,91 @@\n+var test = require('tape');\n+var nock = require('nock');\n+var meetup = require('../index');\n+\n+test('create() function output type', assert => {\n+  var config = require('../common/config');\n+  meetup.init(config);\n+\n+  const actual = meetup.create() instanceof Promise;\n+  const expected = true;\n+\n+  assert.equal(actual, expected, 'meetup.create() should return a Promise.');\n+\n+  assert.end();\n+});\n+\n+test('create() should not do anything if plugin is disabled', assert => {\n+  var config = require('../common/config');\n+  config.plugins.meetup.enabled = false;\n+  meetup.init(config);\n+  var event = require('./data/event');\n+\n+  const actual = meetup.create(event);\n+  const expected = 'meetup plugin is disabeld.';\n+\n+  // assert.equal(actual, expected, 'meetup.create()');\n+  actual.then((actual) => {\n+    assert.equal(actual, expected);\n+    config.plugins.meetup.enabled = true;\n+    assert.end();\n+  });\n+\n+  actual.catch(() => {\n+    assert.fail('should not get here.');\n+    assert.end();\n+  });\n+});\n+\n+test('create() should create an event on meetup.com', assert => {\n+  var config = require('../common/config');\n+  var event = require('./data/event');\n+  meetup.init(config);\n+\n+  nock('https://api.meetup.com:443', {\n+      'encodedQueryParams': true\n+    })\n+    .post('/2/event')\n+    .query({\n+      'group_id': '18232090',\n+      'name': 'BarcelonaJS%20Meetup.com',\n+      'venue_visibility': 'public',\n+      'hosts': '194993837',\n+      'group_urlname': 'http%3A%2F%2Fbarcelonajs.org',\n+      'simple_html_description': 'This%20slot%20could%20be%20yours!%20%3Ca%20href%3D%22https%3A%2F%2Fgithub.com%2FBarcelonaJS%2Fspeakers%22%3ESubmit%20your%20talk%20now%3C%2Fa%3E.%20You%20did%20some%20crazy%20stuff%20with%20JavaScript%3F%20You%20want%20to%20show%20it%20to%20the%20community%3F%20Drop%20us%20a%20line%20on%20your%20topic%20on%20%3Ca%20href%3D%22https%3A%2F%2Ftwitter.com%2Fbcnjs%22%3ETwitter%3C%2Fa%3E.',\n+      'time': '4102422300000',\n+      'duration': '8100000',\n+      'publish_status': 'published',\n+      'venue_id': '13033612',\n+      'key': config.plugins.meetup.apikey\n+    })\n+    .reply(201, ['1f8b08000000000000037d53db6adb40107def574cf7d9d8d24ab664933ad0943e040285144a4120d6d238da44da5df612e1867c4f3fa43fd659d938090dd5839066e79c33337be68905dfd47abf77e8d9265b25f199b1475401d9e689353a286f0f6cc3d0b1196ba48fdf9f856db0d74a5048b4ad45e7ea94e27025ac450b5fb5f24261df8b19f01924659270a05c25068c69377a277b841fdaf62d5c212920080fdf7af1e7b720122ffaa00e224248856df83c2dd25551ce986cd926cd922c5ba59c0e05159da7f3ac5cadf37cc62c1aa91452ce5ef40e9f67ac43d14e3db04d6c4b3a49cac7264cd8f5b221895148df4be7eb97c4c6a2f09127cd976951f06cc9f992040771d8616ddda37995dca26bac345ec652d985d97eefa403d76b0f94441dee100e3a58f7112e047416f79f2ad6796fdca65a548b3be9bbb09b377aa816e7c15edf560b67503ca07515dbde86dd20fdc402349c07507abca816623b879f3a402b5b707a4068acf87500e7c37e0f23f1c2b57814b753759753e6289407afc1757a04397dfa8e707a1882a2b95cc217ab0d0407027aa910b43aa96a239bf8f75e0b9eb43cda630fbb46ddc79abf1f83c732e96db6346b2467f93ad89e2615f1137c1cc7f980e88379670a13c2550bce8ba22c8a55562d88e780eecd35a4740dc18ae31d94e9c9c642293a6ece86383bf09502dc9c95d9d15fec2c45012f23204f139e739e9d788369dfb5c79dd5c1c4b5b9d752d5836ea39636a8d81b4b1124e5699e4f5cff56c44e44f5d9fb936cb1e2eb6c9d2fb3d316943ce3c93a5663fbff919c7624aa25e9922fcba25c272bb27da709f26210721aa38d715ef8e0e824181a895477ecf9c35f91bd5fda26040000'], {\n+      server: 'cloudflare-nginx',\n+      date: 'Sat, 02 Jan 2016 22:05:52 GMT',\n+      'content-type': 'application/json;charset=utf-8',\n+      'content-length': '628',\n+      connection: 'close',\n+      'set-cookie': ['__cfduid=d598ac3395235c9d43849cdcc8024cbeb1451772351; expires=Sun, 01-Jan-17 22:05:51 GMT; path=/; domain=.meetup.com; HttpOnly'],\n+      'x-meetup-server': 'api10',\n+      'x-ratelimit-limit': '30',\n+      'x-ratelimit-remaining': '29',\n+      'x-ratelimit-reset': '10',\n+      'x-oauth-scopes': 'basic',\n+      'x-accepted-oauth-scopes': 'basic',\n+      location: 'https://api.meetup.com/2/event/227787763',\n+      vary: 'Accept-Encoding,User-Agent',\n+      'content-encoding': 'gzip'\n+    });\n+\n+  const actual = meetup.create(event);\n+  const expected = '227787763';\n+\n+  actual.then((actual) => {","path":"tests/events.js","position":82,"original_position":82,"commit_id":"ed95f3e8a54dcf1bc2b4dcad387714bb7a4a9405","original_commit_id":"ed95f3e8a54dcf1bc2b4dcad387714bb7a4a9405","user":{"login":"houndci","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci","html_url":"https://github.com/houndci","followers_url":"https://api.github.com/users/houndci/followers","following_url":"https://api.github.com/users/houndci/following{/other_user}","gists_url":"https://api.github.com/users/houndci/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci/subscriptions","organizations_url":"https://api.github.com/users/houndci/orgs","repos_url":"https://api.github.com/users/houndci/repos","events_url":"https://api.github.com/users/houndci/events{/privacy}","received_events_url":"https://api.github.com/users/houndci/received_events","type":"User","site_admin":false},"body":"'arrow function syntax (=>)' is only available in ES6 (use esnext option).","created_at":"2016-01-02T22:16:21Z","updated_at":"2016-01-02T22:16:21Z","html_url":"https://github.com/gitevents/gitevents-meetup/pull/6#discussion_r48688096","pull_request_url":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/6","_links":{"self":{"href":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/comments/48688096"},"html":{"href":"https://github.com/gitevents/gitevents-meetup/pull/6#discussion_r48688096"},"pull_request":{"href":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/6"}}},"pull_request":{"url":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/6","id":54913696,"html_url":"https://github.com/gitevents/gitevents-meetup/pull/6","diff_url":"https://github.com/gitevents/gitevents-meetup/pull/6.diff","patch_url":"https://github.com/gitevents/gitevents-meetup/pull/6.patch","issue_url":"https://api.github.com/repos/gitevents/gitevents-meetup/issues/6","number":6,"state":"closed","locked":false,"title":"rewrite to match the new core","user":{"login":"PatrickHeneise","id":74390,"avatar_url":"https://avatars.githubusercontent.com/u/74390?v=3","gravatar_id":"","url":"https://api.github.com/users/PatrickHeneise","html_url":"https://github.com/PatrickHeneise","followers_url":"https://api.github.com/users/PatrickHeneise/followers","following_url":"https://api.github.com/users/PatrickHeneise/following{/other_user}","gists_url":"https://api.github.com/users/PatrickHeneise/gists{/gist_id}","starred_url":"https://api.github.com/users/PatrickHeneise/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PatrickHeneise/subscriptions","organizations_url":"https://api.github.com/users/PatrickHeneise/orgs","repos_url":"https://api.github.com/users/PatrickHeneise/repos","events_url":"https://api.github.com/users/PatrickHeneise/events{/privacy}","received_events_url":"https://api.github.com/users/PatrickHeneise/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-01-02T22:16:14Z","updated_at":"2016-01-02T22:16:22Z","closed_at":"2016-01-02T22:16:17Z","merged_at":"2016-01-02T22:16:17Z","merge_commit_sha":"e7c2b910587c7a0eba77ca52b9b4719dae355052","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/6/commits","review_comments_url":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/6/comments","review_comment_url":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/comments{/number}","comments_url":"https://api.github.com/repos/gitevents/gitevents-meetup/issues/6/comments","statuses_url":"https://api.github.com/repos/gitevents/gitevents-meetup/statuses/ed95f3e8a54dcf1bc2b4dcad387714bb7a4a9405","head":{"label":"PatrickHeneise:master","ref":"master","sha":"ed95f3e8a54dcf1bc2b4dcad387714bb7a4a9405","user":{"login":"PatrickHeneise","id":74390,"avatar_url":"https://avatars.githubusercontent.com/u/74390?v=3","gravatar_id":"","url":"https://api.github.com/users/PatrickHeneise","html_url":"https://github.com/PatrickHeneise","followers_url":"https://api.github.com/users/PatrickHeneise/followers","following_url":"https://api.github.com/users/PatrickHeneise/following{/other_user}","gists_url":"https://api.github.com/users/PatrickHeneise/gists{/gist_id}","starred_url":"https://api.github.com/users/PatrickHeneise/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PatrickHeneise/subscriptions","organizations_url":"https://api.github.com/users/PatrickHeneise/orgs","repos_url":"https://api.github.com/users/PatrickHeneise/repos","events_url":"https://api.github.com/users/PatrickHeneise/events{/privacy}","received_events_url":"https://api.github.com/users/PatrickHeneise/received_events","type":"User","site_admin":false},"repo":{"id":40267382,"name":"gitevents-meetup","full_name":"PatrickHeneise/gitevents-meetup","owner":{"login":"PatrickHeneise","id":74390,"avatar_url":"https://avatars.githubusercontent.com/u/74390?v=3","gravatar_id":"","url":"https://api.github.com/users/PatrickHeneise","html_url":"https://github.com/PatrickHeneise","followers_url":"https://api.github.com/users/PatrickHeneise/followers","following_url":"https://api.github.com/users/PatrickHeneise/following{/other_user}","gists_url":"https://api.github.com/users/PatrickHeneise/gists{/gist_id}","starred_url":"https://api.github.com/users/PatrickHeneise/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PatrickHeneise/subscriptions","organizations_url":"https://api.github.com/users/PatrickHeneise/orgs","repos_url":"https://api.github.com/users/PatrickHeneise/repos","events_url":"https://api.github.com/users/PatrickHeneise/events{/privacy}","received_events_url":"https://api.github.com/users/PatrickHeneise/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/PatrickHeneise/gitevents-meetup","description":"Meetup plugin for GitUp","fork":true,"url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup","forks_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/forks","keys_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/keys{/key_id}","collaborators_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/teams","hooks_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/hooks","issue_events_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/issues/events{/number}","events_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/events","assignees_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/assignees{/user}","branches_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/branches{/branch}","tags_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/tags","blobs_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/git/refs{/sha}","trees_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/git/trees{/sha}","statuses_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/statuses/{sha}","languages_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/languages","stargazers_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/stargazers","contributors_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/contributors","subscribers_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/subscribers","subscription_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/subscription","commits_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/commits{/sha}","git_commits_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/git/commits{/sha}","comments_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/comments{/number}","issue_comment_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/issues/comments{/number}","contents_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/contents/{+path}","compare_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/compare/{base}...{head}","merges_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/merges","archive_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/downloads","issues_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/issues{/number}","pulls_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/pulls{/number}","milestones_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/milestones{/number}","notifications_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/labels{/name}","releases_url":"https://api.github.com/repos/PatrickHeneise/gitevents-meetup/releases{/id}","created_at":"2015-08-05T20:29:36Z","updated_at":"2015-08-05T20:29:36Z","pushed_at":"2016-01-02T22:15:21Z","git_url":"git://github.com/PatrickHeneise/gitevents-meetup.git","ssh_url":"git@github.com:PatrickHeneise/gitevents-meetup.git","clone_url":"https://github.com/PatrickHeneise/gitevents-meetup.git","svn_url":"https://github.com/PatrickHeneise/gitevents-meetup","homepage":null,"size":19,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","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":"gitevents:master","ref":"master","sha":"2b45fe5e7934a7e21faba8ae9a7b6f143238bd9b","user":{"login":"gitevents","id":10575431,"avatar_url":"https://avatars.githubusercontent.com/u/10575431?v=3","gravatar_id":"","url":"https://api.github.com/users/gitevents","html_url":"https://github.com/gitevents","followers_url":"https://api.github.com/users/gitevents/followers","following_url":"https://api.github.com/users/gitevents/following{/other_user}","gists_url":"https://api.github.com/users/gitevents/gists{/gist_id}","starred_url":"https://api.github.com/users/gitevents/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gitevents/subscriptions","organizations_url":"https://api.github.com/users/gitevents/orgs","repos_url":"https://api.github.com/users/gitevents/repos","events_url":"https://api.github.com/users/gitevents/events{/privacy}","received_events_url":"https://api.github.com/users/gitevents/received_events","type":"Organization","site_admin":false},"repo":{"id":29399431,"name":"gitevents-meetup","full_name":"gitevents/gitevents-meetup","owner":{"login":"gitevents","id":10575431,"avatar_url":"https://avatars.githubusercontent.com/u/10575431?v=3","gravatar_id":"","url":"https://api.github.com/users/gitevents","html_url":"https://github.com/gitevents","followers_url":"https://api.github.com/users/gitevents/followers","following_url":"https://api.github.com/users/gitevents/following{/other_user}","gists_url":"https://api.github.com/users/gitevents/gists{/gist_id}","starred_url":"https://api.github.com/users/gitevents/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gitevents/subscriptions","organizations_url":"https://api.github.com/users/gitevents/orgs","repos_url":"https://api.github.com/users/gitevents/repos","events_url":"https://api.github.com/users/gitevents/events{/privacy}","received_events_url":"https://api.github.com/users/gitevents/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gitevents/gitevents-meetup","description":"Meetup plugin for GitUp","fork":true,"url":"https://api.github.com/repos/gitevents/gitevents-meetup","forks_url":"https://api.github.com/repos/gitevents/gitevents-meetup/forks","keys_url":"https://api.github.com/repos/gitevents/gitevents-meetup/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gitevents/gitevents-meetup/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gitevents/gitevents-meetup/teams","hooks_url":"https://api.github.com/repos/gitevents/gitevents-meetup/hooks","issue_events_url":"https://api.github.com/repos/gitevents/gitevents-meetup/issues/events{/number}","events_url":"https://api.github.com/repos/gitevents/gitevents-meetup/events","assignees_url":"https://api.github.com/repos/gitevents/gitevents-meetup/assignees{/user}","branches_url":"https://api.github.com/repos/gitevents/gitevents-meetup/branches{/branch}","tags_url":"https://api.github.com/repos/gitevents/gitevents-meetup/tags","blobs_url":"https://api.github.com/repos/gitevents/gitevents-meetup/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gitevents/gitevents-meetup/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gitevents/gitevents-meetup/git/refs{/sha}","trees_url":"https://api.github.com/repos/gitevents/gitevents-meetup/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gitevents/gitevents-meetup/statuses/{sha}","languages_url":"https://api.github.com/repos/gitevents/gitevents-meetup/languages","stargazers_url":"https://api.github.com/repos/gitevents/gitevents-meetup/stargazers","contributors_url":"https://api.github.com/repos/gitevents/gitevents-meetup/contributors","subscribers_url":"https://api.github.com/repos/gitevents/gitevents-meetup/subscribers","subscription_url":"https://api.github.com/repos/gitevents/gitevents-meetup/subscription","commits_url":"https://api.github.com/repos/gitevents/gitevents-meetup/commits{/sha}","git_commits_url":"https://api.github.com/repos/gitevents/gitevents-meetup/git/commits{/sha}","comments_url":"https://api.github.com/repos/gitevents/gitevents-meetup/comments{/number}","issue_comment_url":"https://api.github.com/repos/gitevents/gitevents-meetup/issues/comments{/number}","contents_url":"https://api.github.com/repos/gitevents/gitevents-meetup/contents/{+path}","compare_url":"https://api.github.com/repos/gitevents/gitevents-meetup/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gitevents/gitevents-meetup/merges","archive_url":"https://api.github.com/repos/gitevents/gitevents-meetup/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gitevents/gitevents-meetup/downloads","issues_url":"https://api.github.com/repos/gitevents/gitevents-meetup/issues{/number}","pulls_url":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls{/number}","milestones_url":"https://api.github.com/repos/gitevents/gitevents-meetup/milestones{/number}","notifications_url":"https://api.github.com/repos/gitevents/gitevents-meetup/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gitevents/gitevents-meetup/labels{/name}","releases_url":"https://api.github.com/repos/gitevents/gitevents-meetup/releases{/id}","created_at":"2015-01-17T17:36:55Z","updated_at":"2015-01-19T16:45:16Z","pushed_at":"2016-01-02T22:16:17Z","git_url":"git://github.com/gitevents/gitevents-meetup.git","ssh_url":"git@github.com:gitevents/gitevents-meetup.git","clone_url":"https://github.com/gitevents/gitevents-meetup.git","svn_url":"https://github.com/gitevents/gitevents-meetup","homepage":null,"size":21,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":0,"forks":1,"open_issues":0,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/6"},"html":{"href":"https://github.com/gitevents/gitevents-meetup/pull/6"},"issue":{"href":"https://api.github.com/repos/gitevents/gitevents-meetup/issues/6"},"comments":{"href":"https://api.github.com/repos/gitevents/gitevents-meetup/issues/6/comments"},"review_comments":{"href":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/6/comments"},"review_comment":{"href":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/gitevents/gitevents-meetup/pulls/6/commits"},"statuses":{"href":"https://api.github.com/repos/gitevents/gitevents-meetup/statuses/ed95f3e8a54dcf1bc2b4dcad387714bb7a4a9405"}}}}