{"action":"closed","number":8,"pull_request":{"url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/pulls/8","id":166943210,"html_url":"https://github.com/gr2m/octokit-rest-browser-experimental/pull/8","diff_url":"https://github.com/gr2m/octokit-rest-browser-experimental/pull/8.diff","patch_url":"https://github.com/gr2m/octokit-rest-browser-experimental/pull/8.patch","issue_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/issues/8","number":8,"state":"closed","locked":false,"title":"WIP: tests passing in Mocha (Node), same tests in Cypress (browser)","user":{"login":"bahmutov","id":2212006,"avatar_url":"https://avatars1.githubusercontent.com/u/2212006?v=4","gravatar_id":"","url":"https://api.github.com/users/bahmutov","html_url":"https://github.com/bahmutov","followers_url":"https://api.github.com/users/bahmutov/followers","following_url":"https://api.github.com/users/bahmutov/following{/other_user}","gists_url":"https://api.github.com/users/bahmutov/gists{/gist_id}","starred_url":"https://api.github.com/users/bahmutov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bahmutov/subscriptions","organizations_url":"https://api.github.com/users/bahmutov/orgs","repos_url":"https://api.github.com/users/bahmutov/repos","events_url":"https://api.github.com/users/bahmutov/events{/privacy}","received_events_url":"https://api.github.com/users/bahmutov/received_events","type":"User","site_admin":false},"body":"All tests use same syntax and run under Node (Mocha) and all in browser (Cypress). Only thing not working are loading fixtures.\r\n\r\nMain changes:\r\n\r\n- use `expect` instead of `should`\r\n- use `cy.stub` instead of `simple-mock` which is built into Cypress and is just `sinon`\r\n- loading fixtures is work in progress, have to see how they are done, probably can abstract that as well\r\n- all Node Mocha stuff is in single file [test/mocha-options.js](test/mocha-options.js) which makes every spec file much simpler\r\n\r\n```js\r\nrequire('../mocha-options')\r\nconst GitHub = require('../../')\r\n// tests\r\n```","created_at":"2018-02-03T03:08:17Z","updated_at":"2018-02-08T21:05:38Z","closed_at":"2018-02-08T21:05:38Z","merged_at":null,"merge_commit_sha":null,"assignee":{"login":"gr2m","id":39992,"avatar_url":"https://avatars3.githubusercontent.com/u/39992?v=4","gravatar_id":"","url":"https://api.github.com/users/gr2m","html_url":"https://github.com/gr2m","followers_url":"https://api.github.com/users/gr2m/followers","following_url":"https://api.github.com/users/gr2m/following{/other_user}","gists_url":"https://api.github.com/users/gr2m/gists{/gist_id}","starred_url":"https://api.github.com/users/gr2m/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gr2m/subscriptions","organizations_url":"https://api.github.com/users/gr2m/orgs","repos_url":"https://api.github.com/users/gr2m/repos","events_url":"https://api.github.com/users/gr2m/events{/privacy}","received_events_url":"https://api.github.com/users/gr2m/received_events","type":"User","site_admin":false},"assignees":[{"login":"gr2m","id":39992,"avatar_url":"https://avatars3.githubusercontent.com/u/39992?v=4","gravatar_id":"","url":"https://api.github.com/users/gr2m","html_url":"https://github.com/gr2m","followers_url":"https://api.github.com/users/gr2m/followers","following_url":"https://api.github.com/users/gr2m/following{/other_user}","gists_url":"https://api.github.com/users/gr2m/gists{/gist_id}","starred_url":"https://api.github.com/users/gr2m/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gr2m/subscriptions","organizations_url":"https://api.github.com/users/gr2m/orgs","repos_url":"https://api.github.com/users/gr2m/repos","events_url":"https://api.github.com/users/gr2m/events{/privacy}","received_events_url":"https://api.github.com/users/gr2m/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"milestone":null,"commits_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/pulls/8/commits","review_comments_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/pulls/8/comments","review_comment_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/pulls/comments{/number}","comments_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/issues/8/comments","statuses_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/statuses/9c1a190c1ad6f97a462af74170b068447f888cc4","head":{"label":"bahmutov:master","ref":"master","sha":"9c1a190c1ad6f97a462af74170b068447f888cc4","user":{"login":"bahmutov","id":2212006,"avatar_url":"https://avatars1.githubusercontent.com/u/2212006?v=4","gravatar_id":"","url":"https://api.github.com/users/bahmutov","html_url":"https://github.com/bahmutov","followers_url":"https://api.github.com/users/bahmutov/followers","following_url":"https://api.github.com/users/bahmutov/following{/other_user}","gists_url":"https://api.github.com/users/bahmutov/gists{/gist_id}","starred_url":"https://api.github.com/users/bahmutov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bahmutov/subscriptions","organizations_url":"https://api.github.com/users/bahmutov/orgs","repos_url":"https://api.github.com/users/bahmutov/repos","events_url":"https://api.github.com/users/bahmutov/events{/privacy}","received_events_url":"https://api.github.com/users/bahmutov/received_events","type":"User","site_admin":false},"repo":{"id":120007662,"name":"octokit-rest-browser-experimental","full_name":"bahmutov/octokit-rest-browser-experimental","owner":{"login":"bahmutov","id":2212006,"avatar_url":"https://avatars1.githubusercontent.com/u/2212006?v=4","gravatar_id":"","url":"https://api.github.com/users/bahmutov","html_url":"https://github.com/bahmutov","followers_url":"https://api.github.com/users/bahmutov/followers","following_url":"https://api.github.com/users/bahmutov/following{/other_user}","gists_url":"https://api.github.com/users/bahmutov/gists{/gist_id}","starred_url":"https://api.github.com/users/bahmutov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bahmutov/subscriptions","organizations_url":"https://api.github.com/users/bahmutov/orgs","repos_url":"https://api.github.com/users/bahmutov/repos","events_url":"https://api.github.com/users/bahmutov/events{/privacy}","received_events_url":"https://api.github.com/users/bahmutov/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/bahmutov/octokit-rest-browser-experimental","description":"GitHub REST API client for Node.js","fork":true,"url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental","forks_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/forks","keys_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/teams","hooks_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/hooks","issue_events_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/issues/events{/number}","events_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/events","assignees_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/assignees{/user}","branches_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/branches{/branch}","tags_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/tags","blobs_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/git/refs{/sha}","trees_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/statuses/{sha}","languages_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/languages","stargazers_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/stargazers","contributors_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/contributors","subscribers_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/subscribers","subscription_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/subscription","commits_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/commits{/sha}","git_commits_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/git/commits{/sha}","comments_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/comments{/number}","issue_comment_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/issues/comments{/number}","contents_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/contents/{+path}","compare_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/merges","archive_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/downloads","issues_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/issues{/number}","pulls_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/pulls{/number}","milestones_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/milestones{/number}","notifications_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/labels{/name}","releases_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/releases{/id}","deployments_url":"https://api.github.com/repos/bahmutov/octokit-rest-browser-experimental/deployments","created_at":"2018-02-02T16:59:03Z","updated_at":"2018-02-02T16:59:05Z","pushed_at":"2018-02-04T18:28:01Z","git_url":"git://github.com/bahmutov/octokit-rest-browser-experimental.git","ssh_url":"git@github.com:bahmutov/octokit-rest-browser-experimental.git","clone_url":"https://github.com/bahmutov/octokit-rest-browser-experimental.git","svn_url":"https://github.com/bahmutov/octokit-rest-browser-experimental","homepage":"https://octokit.github.io/rest.js/","size":4381,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"gr2m:master","ref":"master","sha":"feca70ec0d0623b73b0160a6e3626dc4d0d987ba","user":{"login":"gr2m","id":39992,"avatar_url":"https://avatars3.githubusercontent.com/u/39992?v=4","gravatar_id":"","url":"https://api.github.com/users/gr2m","html_url":"https://github.com/gr2m","followers_url":"https://api.github.com/users/gr2m/followers","following_url":"https://api.github.com/users/gr2m/following{/other_user}","gists_url":"https://api.github.com/users/gr2m/gists{/gist_id}","starred_url":"https://api.github.com/users/gr2m/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gr2m/subscriptions","organizations_url":"https://api.github.com/users/gr2m/orgs","repos_url":"https://api.github.com/users/gr2m/repos","events_url":"https://api.github.com/users/gr2m/events{/privacy}","received_events_url":"https://api.github.com/users/gr2m/received_events","type":"User","site_admin":false},"repo":{"id":118937669,"name":"octokit-rest-browser-experimental","full_name":"gr2m/octokit-rest-browser-experimental","owner":{"login":"gr2m","id":39992,"avatar_url":"https://avatars3.githubusercontent.com/u/39992?v=4","gravatar_id":"","url":"https://api.github.com/users/gr2m","html_url":"https://github.com/gr2m","followers_url":"https://api.github.com/users/gr2m/followers","following_url":"https://api.github.com/users/gr2m/following{/other_user}","gists_url":"https://api.github.com/users/gr2m/gists{/gist_id}","starred_url":"https://api.github.com/users/gr2m/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gr2m/subscriptions","organizations_url":"https://api.github.com/users/gr2m/orgs","repos_url":"https://api.github.com/users/gr2m/repos","events_url":"https://api.github.com/users/gr2m/events{/privacy}","received_events_url":"https://api.github.com/users/gr2m/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/gr2m/octokit-rest-browser-experimental","description":"GitHub REST API client for Node.js","fork":true,"url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental","forks_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/forks","keys_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/teams","hooks_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/hooks","issue_events_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/issues/events{/number}","events_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/events","assignees_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/assignees{/user}","branches_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/branches{/branch}","tags_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/tags","blobs_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/git/refs{/sha}","trees_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/statuses/{sha}","languages_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/languages","stargazers_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/stargazers","contributors_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/contributors","subscribers_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/subscribers","subscription_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/subscription","commits_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/commits{/sha}","git_commits_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/git/commits{/sha}","comments_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/comments{/number}","issue_comment_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/issues/comments{/number}","contents_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/contents/{+path}","compare_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/merges","archive_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/downloads","issues_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/issues{/number}","pulls_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/pulls{/number}","milestones_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/milestones{/number}","notifications_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/labels{/name}","releases_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/releases{/id}","deployments_url":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/deployments","created_at":"2018-01-25T16:24:49Z","updated_at":"2018-01-25T16:25:22Z","pushed_at":"2018-02-08T21:05:38Z","git_url":"git://github.com/gr2m/octokit-rest-browser-experimental.git","ssh_url":"git@github.com:gr2m/octokit-rest-browser-experimental.git","clone_url":"https://github.com/gr2m/octokit-rest-browser-experimental.git","svn_url":"https://github.com/gr2m/octokit-rest-browser-experimental","homepage":"https://octokit.github.io/rest.js/","size":4408,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":3,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":1,"open_issues":3,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/pulls/8"},"html":{"href":"https://github.com/gr2m/octokit-rest-browser-experimental/pull/8"},"issue":{"href":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/issues/8"},"comments":{"href":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/issues/8/comments"},"review_comments":{"href":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/pulls/8/comments"},"review_comment":{"href":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/pulls/8/commits"},"statuses":{"href":"https://api.github.com/repos/gr2m/octokit-rest-browser-experimental/statuses/9c1a190c1ad6f97a462af74170b068447f888cc4"}},"author_association":"COLLABORATOR","merged":false,"mergeable":false,"rebaseable":false,"mergeable_state":"dirty","merged_by":null,"comments":10,"review_comments":12,"maintainer_can_modify":false,"commits":9,"additions":139,"deletions":241,"changed_files":28}}
{"actor":{"display_login":"gr2m"}}