{"action":"created","comment":{"url":"https://api.github.com/repos/nodejs/node/pulls/comments/136696976","pull_request_review_id":60276854,"id":136696976,"diff_hunk":"@@ -0,0 +1,30 @@\n+/* eslint-disable required-modules */\n+\n+'use strict';\n+\n+const assert = require('assert');\n+const fork = require('child_process').fork;\n+const path = require('path');\n+\n+const runjs = path.join(__dirname, '..', '..', 'benchmark', 'run.js');\n+\n+function runBenchmark(name, args, env) {\n+  const argv = [];\n+\n+  for (let i = 0; i < args.length; i++) {\n+    argv.push('--set');\n+    argv.push(args[i]);","path":"test/common/benchmark.js","position":16,"original_position":16,"commit_id":"4cfc68199ffaa53cb4efb613ab3cdeabd415b188","original_commit_id":"4cfc68199ffaa53cb4efb613ab3cdeabd415b188","user":{"login":"TimothyGu","id":1538624,"avatar_url":"https://avatars2.githubusercontent.com/u/1538624?v=4","gravatar_id":"","url":"https://api.github.com/users/TimothyGu","html_url":"https://github.com/TimothyGu","followers_url":"https://api.github.com/users/TimothyGu/followers","following_url":"https://api.github.com/users/TimothyGu/following{/other_user}","gists_url":"https://api.github.com/users/TimothyGu/gists{/gist_id}","starred_url":"https://api.github.com/users/TimothyGu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TimothyGu/subscriptions","organizations_url":"https://api.github.com/users/TimothyGu/orgs","repos_url":"https://api.github.com/users/TimothyGu/repos","events_url":"https://api.github.com/users/TimothyGu/events{/privacy}","received_events_url":"https://api.github.com/users/TimothyGu/received_events","type":"User","site_admin":false},"body":"Nit: a for-of loop could be used here, and the argv.push lines can be coalesced.","created_at":"2017-09-02T14:37:37Z","updated_at":"2017-09-02T14:40:54Z","html_url":"https://github.com/nodejs/node/pull/15004#discussion_r136696976","pull_request_url":"https://api.github.com/repos/nodejs/node/pulls/15004","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/nodejs/node/pulls/comments/136696976"},"html":{"href":"https://github.com/nodejs/node/pull/15004#discussion_r136696976"},"pull_request":{"href":"https://api.github.com/repos/nodejs/node/pulls/15004"}}},"pull_request":{"url":"https://api.github.com/repos/nodejs/node/pulls/15004","id":137386850,"html_url":"https://github.com/nodejs/node/pull/15004","diff_url":"https://github.com/nodejs/node/pull/15004.diff","patch_url":"https://github.com/nodejs/node/pull/15004.patch","issue_url":"https://api.github.com/repos/nodejs/node/issues/15004","number":15004,"state":"open","locked":false,"title":"test, benchmark: create shared runBenchmark func","user":{"login":"maclover7","id":3020626,"avatar_url":"https://avatars1.githubusercontent.com/u/3020626?v=4","gravatar_id":"","url":"https://api.github.com/users/maclover7","html_url":"https://github.com/maclover7","followers_url":"https://api.github.com/users/maclover7/followers","following_url":"https://api.github.com/users/maclover7/following{/other_user}","gists_url":"https://api.github.com/users/maclover7/gists{/gist_id}","starred_url":"https://api.github.com/users/maclover7/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maclover7/subscriptions","organizations_url":"https://api.github.com/users/maclover7/orgs","repos_url":"https://api.github.com/users/maclover7/repos","events_url":"https://api.github.com/users/maclover7/events{/privacy}","received_events_url":"https://api.github.com/users/maclover7/received_events","type":"User","site_admin":false},"body":"Created from discussion starting at https://github.com/nodejs/node/pull/14951#issuecomment-324542616. This is a proof of concept PR, and the exact implementation details can be tweaked, but I think this is generally what the API should look like. A few open points are below.\r\n\r\nNeeded for merge: **all resolved**\r\n- [x] ESLint is raising with `Mandatory module \"common\" must be loaded  required-modules` right now -- should files matching `test-benchmark-*.js`need to require `common` anymore? **resolved**\r\n\r\nCan probably be handled after merge:\r\n- [x] Does this new helper method need to be documented in `test/common/README.md`?\r\n- [ ] To a novice, it seems like `n=1` is being everywhere except a few places -- should this become an included-by-default argv option in the new run method?\r\n- [ ] exchange `args` array option for an object instead\r\n\r\n##### Checklist\r\n\r\n- [x] `make -j4 test` (UNIX), or `vcbuild test` (Windows) passes \r\n- [x] commit message follows [commit guidelines](https://github.com/nodejs/node/blob/master/CONTRIBUTING.md#commit-message-guidelines)\r\n\r\n##### Affected core subsystem(s)\r\n\r\ntest, benchmark\r\n","created_at":"2017-08-24T07:31:02Z","updated_at":"2017-09-02T14:40:54Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3890c6311c59d3d26cefa9568bd250fb2003dfdb","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/nodejs/node/pulls/15004/commits","review_comments_url":"https://api.github.com/repos/nodejs/node/pulls/15004/comments","review_comment_url":"https://api.github.com/repos/nodejs/node/pulls/comments{/number}","comments_url":"https://api.github.com/repos/nodejs/node/issues/15004/comments","statuses_url":"https://api.github.com/repos/nodejs/node/statuses/4cfc68199ffaa53cb4efb613ab3cdeabd415b188","head":{"label":"maclover7:jm-common-benchmark","ref":"jm-common-benchmark","sha":"4cfc68199ffaa53cb4efb613ab3cdeabd415b188","user":{"login":"maclover7","id":3020626,"avatar_url":"https://avatars1.githubusercontent.com/u/3020626?v=4","gravatar_id":"","url":"https://api.github.com/users/maclover7","html_url":"https://github.com/maclover7","followers_url":"https://api.github.com/users/maclover7/followers","following_url":"https://api.github.com/users/maclover7/following{/other_user}","gists_url":"https://api.github.com/users/maclover7/gists{/gist_id}","starred_url":"https://api.github.com/users/maclover7/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maclover7/subscriptions","organizations_url":"https://api.github.com/users/maclover7/orgs","repos_url":"https://api.github.com/users/maclover7/repos","events_url":"https://api.github.com/users/maclover7/events{/privacy}","received_events_url":"https://api.github.com/users/maclover7/received_events","type":"User","site_admin":false},"repo":{"id":100735358,"name":"node","full_name":"maclover7/node","owner":{"login":"maclover7","id":3020626,"avatar_url":"https://avatars1.githubusercontent.com/u/3020626?v=4","gravatar_id":"","url":"https://api.github.com/users/maclover7","html_url":"https://github.com/maclover7","followers_url":"https://api.github.com/users/maclover7/followers","following_url":"https://api.github.com/users/maclover7/following{/other_user}","gists_url":"https://api.github.com/users/maclover7/gists{/gist_id}","starred_url":"https://api.github.com/users/maclover7/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maclover7/subscriptions","organizations_url":"https://api.github.com/users/maclover7/orgs","repos_url":"https://api.github.com/users/maclover7/repos","events_url":"https://api.github.com/users/maclover7/events{/privacy}","received_events_url":"https://api.github.com/users/maclover7/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/maclover7/node","description":"Node.js JavaScript runtime :sparkles::turtle::rocket::sparkles:","fork":true,"url":"https://api.github.com/repos/maclover7/node","forks_url":"https://api.github.com/repos/maclover7/node/forks","keys_url":"https://api.github.com/repos/maclover7/node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/maclover7/node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/maclover7/node/teams","hooks_url":"https://api.github.com/repos/maclover7/node/hooks","issue_events_url":"https://api.github.com/repos/maclover7/node/issues/events{/number}","events_url":"https://api.github.com/repos/maclover7/node/events","assignees_url":"https://api.github.com/repos/maclover7/node/assignees{/user}","branches_url":"https://api.github.com/repos/maclover7/node/branches{/branch}","tags_url":"https://api.github.com/repos/maclover7/node/tags","blobs_url":"https://api.github.com/repos/maclover7/node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/maclover7/node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/maclover7/node/git/refs{/sha}","trees_url":"https://api.github.com/repos/maclover7/node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/maclover7/node/statuses/{sha}","languages_url":"https://api.github.com/repos/maclover7/node/languages","stargazers_url":"https://api.github.com/repos/maclover7/node/stargazers","contributors_url":"https://api.github.com/repos/maclover7/node/contributors","subscribers_url":"https://api.github.com/repos/maclover7/node/subscribers","subscription_url":"https://api.github.com/repos/maclover7/node/subscription","commits_url":"https://api.github.com/repos/maclover7/node/commits{/sha}","git_commits_url":"https://api.github.com/repos/maclover7/node/git/commits{/sha}","comments_url":"https://api.github.com/repos/maclover7/node/comments{/number}","issue_comment_url":"https://api.github.com/repos/maclover7/node/issues/comments{/number}","contents_url":"https://api.github.com/repos/maclover7/node/contents/{+path}","compare_url":"https://api.github.com/repos/maclover7/node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/maclover7/node/merges","archive_url":"https://api.github.com/repos/maclover7/node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/maclover7/node/downloads","issues_url":"https://api.github.com/repos/maclover7/node/issues{/number}","pulls_url":"https://api.github.com/repos/maclover7/node/pulls{/number}","milestones_url":"https://api.github.com/repos/maclover7/node/milestones{/number}","notifications_url":"https://api.github.com/repos/maclover7/node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/maclover7/node/labels{/name}","releases_url":"https://api.github.com/repos/maclover7/node/releases{/id}","deployments_url":"https://api.github.com/repos/maclover7/node/deployments","created_at":"2017-08-18T17:27:23Z","updated_at":"2017-08-18T17:28:03Z","pushed_at":"2017-09-02T14:33:40Z","git_url":"git://github.com/maclover7/node.git","ssh_url":"git@github.com:maclover7/node.git","clone_url":"https://github.com/maclover7/node.git","svn_url":"https://github.com/maclover7/node","homepage":"https://nodejs.org","size":309896,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"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":"nodejs:master","ref":"master","sha":"f91897e741232552546d2745dd472d1b781cdb11","user":{"login":"nodejs","id":9950313,"avatar_url":"https://avatars3.githubusercontent.com/u/9950313?v=4","gravatar_id":"","url":"https://api.github.com/users/nodejs","html_url":"https://github.com/nodejs","followers_url":"https://api.github.com/users/nodejs/followers","following_url":"https://api.github.com/users/nodejs/following{/other_user}","gists_url":"https://api.github.com/users/nodejs/gists{/gist_id}","starred_url":"https://api.github.com/users/nodejs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nodejs/subscriptions","organizations_url":"https://api.github.com/users/nodejs/orgs","repos_url":"https://api.github.com/users/nodejs/repos","events_url":"https://api.github.com/users/nodejs/events{/privacy}","received_events_url":"https://api.github.com/users/nodejs/received_events","type":"Organization","site_admin":false},"repo":{"id":27193779,"name":"node","full_name":"nodejs/node","owner":{"login":"nodejs","id":9950313,"avatar_url":"https://avatars3.githubusercontent.com/u/9950313?v=4","gravatar_id":"","url":"https://api.github.com/users/nodejs","html_url":"https://github.com/nodejs","followers_url":"https://api.github.com/users/nodejs/followers","following_url":"https://api.github.com/users/nodejs/following{/other_user}","gists_url":"https://api.github.com/users/nodejs/gists{/gist_id}","starred_url":"https://api.github.com/users/nodejs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nodejs/subscriptions","organizations_url":"https://api.github.com/users/nodejs/orgs","repos_url":"https://api.github.com/users/nodejs/repos","events_url":"https://api.github.com/users/nodejs/events{/privacy}","received_events_url":"https://api.github.com/users/nodejs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/nodejs/node","description":"Node.js JavaScript runtime :sparkles::turtle::rocket::sparkles:","fork":false,"url":"https://api.github.com/repos/nodejs/node","forks_url":"https://api.github.com/repos/nodejs/node/forks","keys_url":"https://api.github.com/repos/nodejs/node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nodejs/node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nodejs/node/teams","hooks_url":"https://api.github.com/repos/nodejs/node/hooks","issue_events_url":"https://api.github.com/repos/nodejs/node/issues/events{/number}","events_url":"https://api.github.com/repos/nodejs/node/events","assignees_url":"https://api.github.com/repos/nodejs/node/assignees{/user}","branches_url":"https://api.github.com/repos/nodejs/node/branches{/branch}","tags_url":"https://api.github.com/repos/nodejs/node/tags","blobs_url":"https://api.github.com/repos/nodejs/node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nodejs/node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nodejs/node/git/refs{/sha}","trees_url":"https://api.github.com/repos/nodejs/node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nodejs/node/statuses/{sha}","languages_url":"https://api.github.com/repos/nodejs/node/languages","stargazers_url":"https://api.github.com/repos/nodejs/node/stargazers","contributors_url":"https://api.github.com/repos/nodejs/node/contributors","subscribers_url":"https://api.github.com/repos/nodejs/node/subscribers","subscription_url":"https://api.github.com/repos/nodejs/node/subscription","commits_url":"https://api.github.com/repos/nodejs/node/commits{/sha}","git_commits_url":"https://api.github.com/repos/nodejs/node/git/commits{/sha}","comments_url":"https://api.github.com/repos/nodejs/node/comments{/number}","issue_comment_url":"https://api.github.com/repos/nodejs/node/issues/comments{/number}","contents_url":"https://api.github.com/repos/nodejs/node/contents/{+path}","compare_url":"https://api.github.com/repos/nodejs/node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nodejs/node/merges","archive_url":"https://api.github.com/repos/nodejs/node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nodejs/node/downloads","issues_url":"https://api.github.com/repos/nodejs/node/issues{/number}","pulls_url":"https://api.github.com/repos/nodejs/node/pulls{/number}","milestones_url":"https://api.github.com/repos/nodejs/node/milestones{/number}","notifications_url":"https://api.github.com/repos/nodejs/node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nodejs/node/labels{/name}","releases_url":"https://api.github.com/repos/nodejs/node/releases{/id}","deployments_url":"https://api.github.com/repos/nodejs/node/deployments","created_at":"2014-11-26T19:57:11Z","updated_at":"2017-09-02T13:32:00Z","pushed_at":"2017-09-02T14:33:45Z","git_url":"git://github.com/nodejs/node.git","ssh_url":"git@github.com:nodejs/node.git","clone_url":"https://github.com/nodejs/node.git","svn_url":"https://github.com/nodejs/node","homepage":"https://nodejs.org","size":309638,"stargazers_count":38821,"watchers_count":38821,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7760,"mirror_url":null,"open_issues_count":797,"forks":7760,"open_issues":797,"watchers":38821,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/nodejs/node/pulls/15004"},"html":{"href":"https://github.com/nodejs/node/pull/15004"},"issue":{"href":"https://api.github.com/repos/nodejs/node/issues/15004"},"comments":{"href":"https://api.github.com/repos/nodejs/node/issues/15004/comments"},"review_comments":{"href":"https://api.github.com/repos/nodejs/node/pulls/15004/comments"},"review_comment":{"href":"https://api.github.com/repos/nodejs/node/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/nodejs/node/pulls/15004/commits"},"statuses":{"href":"https://api.github.com/repos/nodejs/node/statuses/4cfc68199ffaa53cb4efb613ab3cdeabd415b188"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"TimothyGu"}}