{"action":"created","comment":{"url":"https://api.github.com/repos/sindresorhus/ava/pulls/comments/52312386","id":52312386,"diff_hunk":"@@ -86,6 +86,12 @@ var oldNodeModulesPaths = module.constructor._nodeModulePaths;\n module.constructor._nodeModulePaths = function () {\n \tvar ret = oldNodeModulesPaths.apply(this, arguments);\n \tret.push(nodeModulesDir);\n+\tif (process.env.NODE_PATH) {\n+\t\tvar osSplitChar = /^win/.test(process.platform) ? ';' : ',';\n+\t\tprocess.env.NODE_PATH.split(osSplitChar).forEach(function (additionalPath) {\n+\t\t\tret.push(path.join(opts.projectRoot, additionalPath));","path":"lib/test-worker.js","position":7,"original_position":7,"commit_id":"669be7cd21162d7c733d8214cf15fb369577f69c","original_commit_id":"669be7cd21162d7c733d8214cf15fb369577f69c","user":{"login":"ingro","id":879431,"avatar_url":"https://avatars.githubusercontent.com/u/879431?v=3","gravatar_id":"","url":"https://api.github.com/users/ingro","html_url":"https://github.com/ingro","followers_url":"https://api.github.com/users/ingro/followers","following_url":"https://api.github.com/users/ingro/following{/other_user}","gists_url":"https://api.github.com/users/ingro/gists{/gist_id}","starred_url":"https://api.github.com/users/ingro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ingro/subscriptions","organizations_url":"https://api.github.com/users/ingro/orgs","repos_url":"https://api.github.com/users/ingro/repos","events_url":"https://api.github.com/users/ingro/events{/privacy}","received_events_url":"https://api.github.com/users/ingro/received_events","type":"User","site_admin":false},"body":"Yeah you're right, I'm really bad at this.","created_at":"2016-02-09T14:20:19Z","updated_at":"2016-02-09T14:20:19Z","html_url":"https://github.com/sindresorhus/ava/pull/531#discussion_r52312386","pull_request_url":"https://api.github.com/repos/sindresorhus/ava/pulls/531","_links":{"self":{"href":"https://api.github.com/repos/sindresorhus/ava/pulls/comments/52312386"},"html":{"href":"https://github.com/sindresorhus/ava/pull/531#discussion_r52312386"},"pull_request":{"href":"https://api.github.com/repos/sindresorhus/ava/pulls/531"}}},"pull_request":{"url":"https://api.github.com/repos/sindresorhus/ava/pulls/531","id":58720779,"html_url":"https://github.com/sindresorhus/ava/pull/531","diff_url":"https://github.com/sindresorhus/ava/pull/531.diff","patch_url":"https://github.com/sindresorhus/ava/pull/531.patch","issue_url":"https://api.github.com/repos/sindresorhus/ava/issues/531","number":531,"state":"open","locked":false,"title":"Support NODE_PATH in forked process","user":{"login":"ingro","id":879431,"avatar_url":"https://avatars.githubusercontent.com/u/879431?v=3","gravatar_id":"","url":"https://api.github.com/users/ingro","html_url":"https://github.com/ingro","followers_url":"https://api.github.com/users/ingro/followers","following_url":"https://api.github.com/users/ingro/following{/other_user}","gists_url":"https://api.github.com/users/ingro/gists{/gist_id}","starred_url":"https://api.github.com/users/ingro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ingro/subscriptions","organizations_url":"https://api.github.com/users/ingro/orgs","repos_url":"https://api.github.com/users/ingro/repos","events_url":"https://api.github.com/users/ingro/events{/privacy}","received_events_url":"https://api.github.com/users/ingro/received_events","type":"User","site_admin":false},"body":"This PR tries to fix #515 in a non-destructive way.\r\n\r\nBasically it checks for the presence of `NODE_PATH` env variable before forking the process and creates an absolute path from it, so it could be used in `test-worker.js` as additional node module path.\r\n\r\nThat won't work there because `process.cwd()` points to the forked process test file.","created_at":"2016-02-09T09:14:23Z","updated_at":"2016-02-09T14:20:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d7a90919d6620706366dd0763bac202a9f9389a8","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/sindresorhus/ava/pulls/531/commits","review_comments_url":"https://api.github.com/repos/sindresorhus/ava/pulls/531/comments","review_comment_url":"https://api.github.com/repos/sindresorhus/ava/pulls/comments{/number}","comments_url":"https://api.github.com/repos/sindresorhus/ava/issues/531/comments","statuses_url":"https://api.github.com/repos/sindresorhus/ava/statuses/669be7cd21162d7c733d8214cf15fb369577f69c","head":{"label":"ingro:master","ref":"master","sha":"669be7cd21162d7c733d8214cf15fb369577f69c","user":{"login":"ingro","id":879431,"avatar_url":"https://avatars.githubusercontent.com/u/879431?v=3","gravatar_id":"","url":"https://api.github.com/users/ingro","html_url":"https://github.com/ingro","followers_url":"https://api.github.com/users/ingro/followers","following_url":"https://api.github.com/users/ingro/following{/other_user}","gists_url":"https://api.github.com/users/ingro/gists{/gist_id}","starred_url":"https://api.github.com/users/ingro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ingro/subscriptions","organizations_url":"https://api.github.com/users/ingro/orgs","repos_url":"https://api.github.com/users/ingro/repos","events_url":"https://api.github.com/users/ingro/events{/privacy}","received_events_url":"https://api.github.com/users/ingro/received_events","type":"User","site_admin":false},"repo":{"id":51356421,"name":"ava","full_name":"ingro/ava","owner":{"login":"ingro","id":879431,"avatar_url":"https://avatars.githubusercontent.com/u/879431?v=3","gravatar_id":"","url":"https://api.github.com/users/ingro","html_url":"https://github.com/ingro","followers_url":"https://api.github.com/users/ingro/followers","following_url":"https://api.github.com/users/ingro/following{/other_user}","gists_url":"https://api.github.com/users/ingro/gists{/gist_id}","starred_url":"https://api.github.com/users/ingro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ingro/subscriptions","organizations_url":"https://api.github.com/users/ingro/orgs","repos_url":"https://api.github.com/users/ingro/repos","events_url":"https://api.github.com/users/ingro/events{/privacy}","received_events_url":"https://api.github.com/users/ingro/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ingro/ava","description":"Futuristic test runner :rocket:","fork":true,"url":"https://api.github.com/repos/ingro/ava","forks_url":"https://api.github.com/repos/ingro/ava/forks","keys_url":"https://api.github.com/repos/ingro/ava/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ingro/ava/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ingro/ava/teams","hooks_url":"https://api.github.com/repos/ingro/ava/hooks","issue_events_url":"https://api.github.com/repos/ingro/ava/issues/events{/number}","events_url":"https://api.github.com/repos/ingro/ava/events","assignees_url":"https://api.github.com/repos/ingro/ava/assignees{/user}","branches_url":"https://api.github.com/repos/ingro/ava/branches{/branch}","tags_url":"https://api.github.com/repos/ingro/ava/tags","blobs_url":"https://api.github.com/repos/ingro/ava/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ingro/ava/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ingro/ava/git/refs{/sha}","trees_url":"https://api.github.com/repos/ingro/ava/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ingro/ava/statuses/{sha}","languages_url":"https://api.github.com/repos/ingro/ava/languages","stargazers_url":"https://api.github.com/repos/ingro/ava/stargazers","contributors_url":"https://api.github.com/repos/ingro/ava/contributors","subscribers_url":"https://api.github.com/repos/ingro/ava/subscribers","subscription_url":"https://api.github.com/repos/ingro/ava/subscription","commits_url":"https://api.github.com/repos/ingro/ava/commits{/sha}","git_commits_url":"https://api.github.com/repos/ingro/ava/git/commits{/sha}","comments_url":"https://api.github.com/repos/ingro/ava/comments{/number}","issue_comment_url":"https://api.github.com/repos/ingro/ava/issues/comments{/number}","contents_url":"https://api.github.com/repos/ingro/ava/contents/{+path}","compare_url":"https://api.github.com/repos/ingro/ava/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ingro/ava/merges","archive_url":"https://api.github.com/repos/ingro/ava/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ingro/ava/downloads","issues_url":"https://api.github.com/repos/ingro/ava/issues{/number}","pulls_url":"https://api.github.com/repos/ingro/ava/pulls{/number}","milestones_url":"https://api.github.com/repos/ingro/ava/milestones{/number}","notifications_url":"https://api.github.com/repos/ingro/ava/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ingro/ava/labels{/name}","releases_url":"https://api.github.com/repos/ingro/ava/releases{/id}","deployments_url":"https://api.github.com/repos/ingro/ava/deployments","created_at":"2016-02-09T09:06:59Z","updated_at":"2016-02-09T09:07:01Z","pushed_at":"2016-02-09T14:02:45Z","git_url":"git://github.com/ingro/ava.git","ssh_url":"git@github.com:ingro/ava.git","clone_url":"https://github.com/ingro/ava.git","svn_url":"https://github.com/ingro/ava","homepage":"","size":3265,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"sindresorhus:master","ref":"master","sha":"f0f4f34438624f3b49c4ffe602de4f261ac66474","user":{"login":"sindresorhus","id":170270,"avatar_url":"https://avatars.githubusercontent.com/u/170270?v=3","gravatar_id":"","url":"https://api.github.com/users/sindresorhus","html_url":"https://github.com/sindresorhus","followers_url":"https://api.github.com/users/sindresorhus/followers","following_url":"https://api.github.com/users/sindresorhus/following{/other_user}","gists_url":"https://api.github.com/users/sindresorhus/gists{/gist_id}","starred_url":"https://api.github.com/users/sindresorhus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sindresorhus/subscriptions","organizations_url":"https://api.github.com/users/sindresorhus/orgs","repos_url":"https://api.github.com/users/sindresorhus/repos","events_url":"https://api.github.com/users/sindresorhus/events{/privacy}","received_events_url":"https://api.github.com/users/sindresorhus/received_events","type":"User","site_admin":false},"repo":{"id":26820798,"name":"ava","full_name":"sindresorhus/ava","owner":{"login":"sindresorhus","id":170270,"avatar_url":"https://avatars.githubusercontent.com/u/170270?v=3","gravatar_id":"","url":"https://api.github.com/users/sindresorhus","html_url":"https://github.com/sindresorhus","followers_url":"https://api.github.com/users/sindresorhus/followers","following_url":"https://api.github.com/users/sindresorhus/following{/other_user}","gists_url":"https://api.github.com/users/sindresorhus/gists{/gist_id}","starred_url":"https://api.github.com/users/sindresorhus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sindresorhus/subscriptions","organizations_url":"https://api.github.com/users/sindresorhus/orgs","repos_url":"https://api.github.com/users/sindresorhus/repos","events_url":"https://api.github.com/users/sindresorhus/events{/privacy}","received_events_url":"https://api.github.com/users/sindresorhus/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/sindresorhus/ava","description":"Futuristic test runner :rocket:","fork":false,"url":"https://api.github.com/repos/sindresorhus/ava","forks_url":"https://api.github.com/repos/sindresorhus/ava/forks","keys_url":"https://api.github.com/repos/sindresorhus/ava/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sindresorhus/ava/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sindresorhus/ava/teams","hooks_url":"https://api.github.com/repos/sindresorhus/ava/hooks","issue_events_url":"https://api.github.com/repos/sindresorhus/ava/issues/events{/number}","events_url":"https://api.github.com/repos/sindresorhus/ava/events","assignees_url":"https://api.github.com/repos/sindresorhus/ava/assignees{/user}","branches_url":"https://api.github.com/repos/sindresorhus/ava/branches{/branch}","tags_url":"https://api.github.com/repos/sindresorhus/ava/tags","blobs_url":"https://api.github.com/repos/sindresorhus/ava/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sindresorhus/ava/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sindresorhus/ava/git/refs{/sha}","trees_url":"https://api.github.com/repos/sindresorhus/ava/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sindresorhus/ava/statuses/{sha}","languages_url":"https://api.github.com/repos/sindresorhus/ava/languages","stargazers_url":"https://api.github.com/repos/sindresorhus/ava/stargazers","contributors_url":"https://api.github.com/repos/sindresorhus/ava/contributors","subscribers_url":"https://api.github.com/repos/sindresorhus/ava/subscribers","subscription_url":"https://api.github.com/repos/sindresorhus/ava/subscription","commits_url":"https://api.github.com/repos/sindresorhus/ava/commits{/sha}","git_commits_url":"https://api.github.com/repos/sindresorhus/ava/git/commits{/sha}","comments_url":"https://api.github.com/repos/sindresorhus/ava/comments{/number}","issue_comment_url":"https://api.github.com/repos/sindresorhus/ava/issues/comments{/number}","contents_url":"https://api.github.com/repos/sindresorhus/ava/contents/{+path}","compare_url":"https://api.github.com/repos/sindresorhus/ava/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sindresorhus/ava/merges","archive_url":"https://api.github.com/repos/sindresorhus/ava/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sindresorhus/ava/downloads","issues_url":"https://api.github.com/repos/sindresorhus/ava/issues{/number}","pulls_url":"https://api.github.com/repos/sindresorhus/ava/pulls{/number}","milestones_url":"https://api.github.com/repos/sindresorhus/ava/milestones{/number}","notifications_url":"https://api.github.com/repos/sindresorhus/ava/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sindresorhus/ava/labels{/name}","releases_url":"https://api.github.com/repos/sindresorhus/ava/releases{/id}","deployments_url":"https://api.github.com/repos/sindresorhus/ava/deployments","created_at":"2014-11-18T17:20:26Z","updated_at":"2016-02-09T13:37:40Z","pushed_at":"2016-02-09T14:02:45Z","git_url":"git://github.com/sindresorhus/ava.git","ssh_url":"git@github.com:sindresorhus/ava.git","clone_url":"https://github.com/sindresorhus/ava.git","svn_url":"https://github.com/sindresorhus/ava","homepage":"","size":3531,"stargazers_count":2534,"watchers_count":2534,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":103,"mirror_url":null,"open_issues_count":97,"forks":103,"open_issues":97,"watchers":2534,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/sindresorhus/ava/pulls/531"},"html":{"href":"https://github.com/sindresorhus/ava/pull/531"},"issue":{"href":"https://api.github.com/repos/sindresorhus/ava/issues/531"},"comments":{"href":"https://api.github.com/repos/sindresorhus/ava/issues/531/comments"},"review_comments":{"href":"https://api.github.com/repos/sindresorhus/ava/pulls/531/comments"},"review_comment":{"href":"https://api.github.com/repos/sindresorhus/ava/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/sindresorhus/ava/pulls/531/commits"},"statuses":{"href":"https://api.github.com/repos/sindresorhus/ava/statuses/669be7cd21162d7c733d8214cf15fb369577f69c"}}}}