Skip to content

Commit 1087acd

Browse files
committed
Updates mocks for no unknown category test
1 parent c9faa4e commit 1087acd

File tree

3 files changed

+227
-0
lines changed

3 files changed

+227
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,132 @@
1+
{
2+
"id": 375534019,
3+
"node_id": "MDEwOlJlcG9zaXRvcnkzNzU1MzQwMTk=",
4+
"name": "testCreateRelease",
5+
"full_name": "hub4j-test-org/testCreateRelease",
6+
"private": false,
7+
"owner": {
8+
"login": "hub4j-test-org",
9+
"id": 7544739,
10+
"node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
11+
"avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
12+
"gravatar_id": "",
13+
"url": "https://api.github.com/users/hub4j-test-org",
14+
"html_url": "https://github.com/hub4j-test-org",
15+
"followers_url": "https://api.github.com/users/hub4j-test-org/followers",
16+
"following_url": "https://api.github.com/users/hub4j-test-org/following{/other_user}",
17+
"gists_url": "https://api.github.com/users/hub4j-test-org/gists{/gist_id}",
18+
"starred_url": "https://api.github.com/users/hub4j-test-org/starred{/owner}{/repo}",
19+
"subscriptions_url": "https://api.github.com/users/hub4j-test-org/subscriptions",
20+
"organizations_url": "https://api.github.com/users/hub4j-test-org/orgs",
21+
"repos_url": "https://api.github.com/users/hub4j-test-org/repos",
22+
"events_url": "https://api.github.com/users/hub4j-test-org/events{/privacy}",
23+
"received_events_url": "https://api.github.com/users/hub4j-test-org/received_events",
24+
"type": "Organization",
25+
"site_admin": false
26+
},
27+
"html_url": "https://github.com/hub4j-test-org/testCreateRelease",
28+
"description": null,
29+
"fork": false,
30+
"url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease",
31+
"forks_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/forks",
32+
"keys_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/keys{/key_id}",
33+
"collaborators_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/collaborators{/collaborator}",
34+
"teams_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/teams",
35+
"hooks_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/hooks",
36+
"issue_events_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/issues/events{/number}",
37+
"events_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/events",
38+
"assignees_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/assignees{/user}",
39+
"branches_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/branches{/branch}",
40+
"tags_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/tags",
41+
"blobs_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/git/blobs{/sha}",
42+
"git_tags_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/git/tags{/sha}",
43+
"git_refs_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/git/refs{/sha}",
44+
"trees_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/git/trees{/sha}",
45+
"statuses_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/statuses/{sha}",
46+
"languages_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/languages",
47+
"stargazers_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/stargazers",
48+
"contributors_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/contributors",
49+
"subscribers_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/subscribers",
50+
"subscription_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/subscription",
51+
"commits_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/commits{/sha}",
52+
"git_commits_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/git/commits{/sha}",
53+
"comments_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/comments{/number}",
54+
"issue_comment_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/issues/comments{/number}",
55+
"contents_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/contents/{+path}",
56+
"compare_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/compare/{base}...{head}",
57+
"merges_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/merges",
58+
"archive_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/{archive_format}{/ref}",
59+
"downloads_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/downloads",
60+
"issues_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/issues{/number}",
61+
"pulls_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/pulls{/number}",
62+
"milestones_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/milestones{/number}",
63+
"notifications_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/notifications{?since,all,participating}",
64+
"labels_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/labels{/name}",
65+
"releases_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/releases{/id}",
66+
"deployments_url": "https://api.github.com/repos/hub4j-test-org/testCreateRelease/deployments",
67+
"created_at": "2021-06-10T01:25:59Z",
68+
"updated_at": "2021-06-10T01:31:14Z",
69+
"pushed_at": "2021-06-11T07:37:21Z",
70+
"git_url": "git://github.com/hub4j-test-org/testCreateRelease.git",
71+
"ssh_url": "[email protected]:hub4j-test-org/testCreateRelease.git",
72+
"clone_url": "https://github.com/hub4j-test-org/testCreateRelease.git",
73+
"svn_url": "https://github.com/hub4j-test-org/testCreateRelease",
74+
"homepage": null,
75+
"size": 11948,
76+
"stargazers_count": 0,
77+
"watchers_count": 0,
78+
"language": "Java",
79+
"has_issues": false,
80+
"has_projects": false,
81+
"has_downloads": true,
82+
"has_wiki": false,
83+
"has_pages": false,
84+
"forks_count": 0,
85+
"mirror_url": null,
86+
"archived": false,
87+
"disabled": false,
88+
"open_issues_count": 0,
89+
"license": {
90+
"key": "mit",
91+
"name": "MIT License",
92+
"spdx_id": "MIT",
93+
"url": "https://api.github.com/licenses/mit",
94+
"node_id": "MDc6TGljZW5zZTEz"
95+
},
96+
"forks": 0,
97+
"open_issues": 0,
98+
"watchers": 0,
99+
"default_branch": "main",
100+
"permissions": {
101+
"admin": true,
102+
"push": true,
103+
"pull": true
104+
},
105+
"temp_clone_token": "",
106+
"allow_squash_merge": true,
107+
"allow_merge_commit": true,
108+
"allow_rebase_merge": true,
109+
"delete_branch_on_merge": false,
110+
"organization": {
111+
"login": "hub4j-test-org",
112+
"id": 7544739,
113+
"node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
114+
"avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
115+
"gravatar_id": "",
116+
"url": "https://api.github.com/users/hub4j-test-org",
117+
"html_url": "https://github.com/hub4j-test-org",
118+
"followers_url": "https://api.github.com/users/hub4j-test-org/followers",
119+
"following_url": "https://api.github.com/users/hub4j-test-org/following{/other_user}",
120+
"gists_url": "https://api.github.com/users/hub4j-test-org/gists{/gist_id}",
121+
"starred_url": "https://api.github.com/users/hub4j-test-org/starred{/owner}{/repo}",
122+
"subscriptions_url": "https://api.github.com/users/hub4j-test-org/subscriptions",
123+
"organizations_url": "https://api.github.com/users/hub4j-test-org/orgs",
124+
"repos_url": "https://api.github.com/users/hub4j-test-org/repos",
125+
"events_url": "https://api.github.com/users/hub4j-test-org/events{/privacy}",
126+
"received_events_url": "https://api.github.com/users/hub4j-test-org/received_events",
127+
"type": "Organization",
128+
"site_admin": false
129+
},
130+
"network_count": 0,
131+
"subscribers_count": 11
132+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
{
2+
"id": "693de905-eed7-4578-9c35-8cbf8437e810",
3+
"name": "repos_hub4j-test-org_testcreaterelease",
4+
"request": {
5+
"url": "/repos/hub4j-test-org/testCreateRelease",
6+
"method": "GET",
7+
"headers": {
8+
"Accept": {
9+
"equalTo": "text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2"
10+
}
11+
}
12+
},
13+
"response": {
14+
"status": 200,
15+
"bodyFileName": "repos_hub4j-test-org_testcreaterelease-1.json",
16+
"headers": {
17+
"Server": "GitHub.com",
18+
"Date": "Fri, 11 Jun 2021 07:56:21 GMT",
19+
"Content-Type": "application/json; charset=utf-8",
20+
"Cache-Control": "private, max-age=60, s-maxage=60",
21+
"Vary": [
22+
"Accept, Authorization, Cookie, X-GitHub-OTP",
23+
"Accept-Encoding, Accept, X-Requested-With"
24+
],
25+
"ETag": "W/\"d38b777b43ef444a13e46dab7310f74f4dec77e2b09228df77a11be4b10d5563\"",
26+
"Last-Modified": "Thu, 10 Jun 2021 01:31:14 GMT",
27+
"X-OAuth-Scopes": "admin:enterprise, admin:gpg_key, admin:org, admin:org_hook, admin:public_key, admin:repo_hook, delete:packages, delete_repo, gist, notifications, repo, user, workflow, write:discussion, write:packages",
28+
"X-Accepted-OAuth-Scopes": "repo",
29+
"X-GitHub-Media-Type": "unknown, github.v3",
30+
"X-RateLimit-Limit": "5000",
31+
"X-RateLimit-Remaining": "4965",
32+
"X-RateLimit-Reset": "1623398211",
33+
"X-RateLimit-Used": "35",
34+
"X-RateLimit-Resource": "core",
35+
"Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
36+
"X-Frame-Options": "deny",
37+
"X-Content-Type-Options": "nosniff",
38+
"X-XSS-Protection": "0",
39+
"Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
40+
"Content-Security-Policy": "default-src 'none'",
41+
"X-GitHub-Request-Id": "F07F:E6B9:1090CB1:10ED5B2:60C31725"
42+
}
43+
},
44+
"uuid": "693de905-eed7-4578-9c35-8cbf8437e810",
45+
"persistent": true,
46+
"insertionIndex": 1
47+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
{
2+
"id": "7ee9d108-2777-4ec1-9a4e-8d25c627bf0c",
3+
"name": "repos_hub4j-test-org_testcreaterelease_releases",
4+
"request": {
5+
"url": "/repos/hub4j-test-org/testCreateRelease/releases",
6+
"method": "POST",
7+
"headers": {
8+
"Accept": {
9+
"equalTo": "text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2"
10+
}
11+
},
12+
"bodyPatterns": [
13+
{
14+
"equalToJson": "{\"discussion_category_name\":\"an invalid cateogry\",\"tag_name\":\"6d7e9956-f735-4f82-9b1b-f1da143ef2e9\",\"prerelease\":false,\"name\":\"release-6d7e9956-f735-4f82-9b1b-f1da143ef2e9\"}",
15+
"ignoreArrayOrder": true,
16+
"ignoreExtraElements": false
17+
}
18+
]
19+
},
20+
"response": {
21+
"status": 404,
22+
"body": "{\"message\":\"Discussion could not be created. Make sure you passed a valid category name.\",\"documentation_url\":\"https://docs.github.com/rest/reference/repos#create-a-release\"}",
23+
"headers": {
24+
"Server": "GitHub.com",
25+
"Date": "Fri, 11 Jun 2021 07:56:22 GMT",
26+
"Content-Type": "application/json; charset=utf-8",
27+
"X-OAuth-Scopes": "admin:enterprise, admin:gpg_key, admin:org, admin:org_hook, admin:public_key, admin:repo_hook, delete:packages, delete_repo, gist, notifications, repo, user, workflow, write:discussion, write:packages",
28+
"X-Accepted-OAuth-Scopes": "repo",
29+
"X-GitHub-Media-Type": "unknown, github.v3",
30+
"X-RateLimit-Limit": "5000",
31+
"X-RateLimit-Remaining": "4964",
32+
"X-RateLimit-Reset": "1623398211",
33+
"X-RateLimit-Used": "36",
34+
"X-RateLimit-Resource": "core",
35+
"Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
36+
"X-Frame-Options": "deny",
37+
"X-Content-Type-Options": "nosniff",
38+
"X-XSS-Protection": "0",
39+
"Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
40+
"Content-Security-Policy": "default-src 'none'",
41+
"Vary": "Accept-Encoding, Accept, X-Requested-With",
42+
"X-GitHub-Request-Id": "F080:2A5F:8D957C:9249B3:60C31725"
43+
}
44+
},
45+
"uuid": "7ee9d108-2777-4ec1-9a4e-8d25c627bf0c",
46+
"persistent": true,
47+
"insertionIndex": 2
48+
}

0 commit comments

Comments
 (0)