diff --git a/COMPATIBILITY.md b/COMPATIBILITY.md index cb38cd9df..07e94b29d 100644 --- a/COMPATIBILITY.md +++ b/COMPATIBILITY.md @@ -34,6 +34,14 @@ In case you find any error, please [create a new issue](https://github.com/packi | ----------------- | :----: | :----: | :----: | :-----: | | `add_label` | ✔ | ✔ | ✘ | ✔ | | `get_all_commits` | ✔ | ✔ | ✘ | ✔ | +| `changes` | ✔ | ✘ | ✘ | ✘ | + +## GitCommit + +| | GitHub | GitLab | Pagure | Forgejo | +| --------- | :----: | :----: | :----: | :-----: | +| `changes` | ✔ | ✘ | ✘ | ✘ | +| `get_prs` | ✘ | ✘ | ✘ | ✘ | ## Release @@ -63,6 +71,7 @@ In case you find any error, please [create a new issue](https://github.com/packi | `which_groups_can_merge_pr` | ✘ | ✘ | ✔ | ✘ | | `get_pr_files_diff` | ✘ | ✘ | ✔ | ✘ | | `get_users_with_given_access` | ✘ | ✘ | ✔ | ✔ | +| `get_commit` | ✔ | ✘ | ✘ | ✘ | ## User diff --git a/ogr/abstract/__init__.py b/ogr/abstract/__init__.py index a3f548f05..c69919042 100644 --- a/ogr/abstract/__init__.py +++ b/ogr/abstract/__init__.py @@ -12,6 +12,7 @@ PRComment, Reaction, ) +from ogr.abstract.commit import GitCommit from ogr.abstract.commit_flag import CommitFlag from ogr.abstract.git_project import GitProject from ogr.abstract.git_service import GitService @@ -34,6 +35,7 @@ PRComment.__name__, Reaction.__name__, CommitFlag.__name__, + GitCommit.__name__, GitProject.__name__, GitService.__name__, GitTag.__name__, diff --git a/ogr/abstract/commit.py b/ogr/abstract/commit.py new file mode 100644 index 000000000..14855c578 --- /dev/null +++ b/ogr/abstract/commit.py @@ -0,0 +1,80 @@ +# Copyright Contributors to the Packit project. +# SPDX-License-Identifier: MIT + +from collections.abc import Iterable +from typing import Any, Union + +from ogr import abstract as _abstract +from ogr.abstract.abstract_class import OgrAbstractClass +from ogr.abstract.git_project import GitProject + + +class GitCommit(OgrAbstractClass): + """ + Class representing a git commit + + Attributes: + project (GitProject): Git project where the commit belongs to. + """ + + def __init__(self, raw_commit: Any, project: "GitProject") -> None: + self._raw_commit = raw_commit + self.project = project + + @property + def sha(self) -> str: + """Commit hash.""" + raise NotImplementedError() + + @property + def changes(self) -> "CommitChanges": + """Commit change information.""" + raise NotImplementedError() + + def get_prs(self) -> Iterable["_abstract.PullRequest"]: + """Get the associated pull requests""" + raise NotImplementedError() + + +class CommitLikeChanges(OgrAbstractClass): + """ + Class representing a commit-like changes. + + Can be from a single commit or aggregated like from a PR. + """ + + @property + def parent(self) -> Union["GitCommit", "_abstract.PullRequest"]: + """Parent object containing the changes.""" + raise NotImplementedError() + + @property + def files(self) -> Union[list[str], Iterable[str]]: + """Files changed by the current change.""" + raise NotImplementedError() + + @property + def patch(self) -> bytes: + """Patch of the changes.""" + raise NotImplementedError() + + @property + def diff_url(self) -> str: + """Web URL to the diff of the pull request.""" + raise NotImplementedError() + + +class CommitChanges(CommitLikeChanges): + """ + Class representing a Commit's change + + Attributes: + commit (GitCommit): Parent commit. + """ + + def __init__(self, commit: "GitCommit") -> None: + self.commit = commit + + @property + def parent(self) -> "GitCommit": + return self.commit diff --git a/ogr/abstract/git_project.py b/ogr/abstract/git_project.py index 0a324403d..dd3936f69 100644 --- a/ogr/abstract/git_project.py +++ b/ogr/abstract/git_project.py @@ -116,6 +116,16 @@ def default_branch(self) -> str: """Default branch (usually `main`, `master` or `trunk`).""" raise NotImplementedError() + def get_commit(self, sha: str) -> "_abstract.GitCommit": + """ + Get a specific commit information. + + Args: + sha: Specific sha of the commit + + """ + raise NotImplementedError() + def get_commits(self, ref: Optional[str] = None) -> Union[list[str], Iterable[str]]: """ Get list of commits for the project. diff --git a/ogr/abstract/pull_request.py b/ogr/abstract/pull_request.py index 8a20fc3d8..3f832da69 100644 --- a/ogr/abstract/pull_request.py +++ b/ogr/abstract/pull_request.py @@ -8,6 +8,7 @@ from ogr import abstract as _abstract from ogr.abstract.abstract_class import OgrAbstractClass +from ogr.abstract.commit import CommitLikeChanges from ogr.abstract.commit_flag import CommitFlag from ogr.abstract.git_project import GitProject from ogr.abstract.status import MergeCommitStatus, PRStatus @@ -81,6 +82,11 @@ def labels(self) -> Union[list["_abstract.PRLabel"], Iterable["_abstract.PRLabel """Labels of the pull request.""" raise NotImplementedError() + @property + def changes(self) -> "PullRequestChanges": + """Commit-like change information.""" + raise NotImplementedError() + @property def diff_url(self) -> str: """Web URL to the diff of the pull request.""" @@ -381,3 +387,19 @@ def get_comment(self, comment_id: int) -> "_abstract.PRComment": Object representing a PR comment. """ raise NotImplementedError() + + +class PullRequestChanges(CommitLikeChanges): + """ + Class representing a PullRequest's changes + + Attributes: + pull_request (PullRequest): Parent pull request. + """ + + def __init__(self, pull_request: "PullRequest") -> None: + self.pull_request = pull_request + + @property + def parent(self) -> "PullRequest": + return self.pull_request diff --git a/ogr/services/base.py b/ogr/services/base.py index 8af7cfc52..b6045d0de 100644 --- a/ogr/services/base.py +++ b/ogr/services/base.py @@ -9,6 +9,7 @@ from ogr.abstract import ( CommitFlag, CommitStatus, + GitCommit, GitProject, GitService, GitUser, @@ -86,6 +87,10 @@ def get_statuses(self) -> Union[list[CommitFlag], Iterable[CommitFlag]]: return self.target_project.get_commit_statuses(commit) +class BaseGitCommit(GitCommit): + pass + + class BaseGitUser(GitUser): pass diff --git a/ogr/services/github/__init__.py b/ogr/services/github/__init__.py index a5fab4bf4..b93aa89b9 100644 --- a/ogr/services/github/__init__.py +++ b/ogr/services/github/__init__.py @@ -3,6 +3,7 @@ from ogr.services.github.check_run import GithubCheckRun from ogr.services.github.comments import GithubIssueComment, GithubPRComment +from ogr.services.github.commit import GithubCommit from ogr.services.github.issue import GithubIssue from ogr.services.github.project import GithubProject from ogr.services.github.pull_request import GithubPullRequest @@ -12,6 +13,7 @@ __all__ = [ GithubCheckRun.__name__, + GithubCommit.__name__, GithubPullRequest.__name__, GithubIssueComment.__name__, GithubPRComment.__name__, diff --git a/ogr/services/github/commit.py b/ogr/services/github/commit.py new file mode 100644 index 000000000..b0eea6166 --- /dev/null +++ b/ogr/services/github/commit.py @@ -0,0 +1,66 @@ +# Copyright Contributors to the Packit project. +# SPDX-License-Identifier: MIT +from collections.abc import Iterable + +import github +import requests +from github.Commit import Commit as _GitCommit + +from ogr.abstract.commit import CommitChanges +from ogr.exceptions import GithubAPIException, OgrNetworkError +from ogr.services import github as ogr_github +from ogr.services.base import BaseGitCommit +from ogr.services.github.pull_request import GithubPullRequest + + +class GithubCommit(BaseGitCommit): + _raw_commit: _GitCommit + _changes: "GithubCommitChanges" = None + + @property + def sha(self) -> str: + return self._raw_commit.sha + + @property + def changes(self) -> "GithubCommitChanges": + if not self._changes: + self._changes = GithubCommitChanges(self) + return self._changes + + def get_prs(self) -> Iterable[GithubPullRequest]: + for pr in self._raw_commit.get_pulls(): + yield GithubPullRequest(pr, self.project) + + @staticmethod + def get(project: "ogr_github.GithubProject", sha: str) -> "GithubCommit": + try: + commit = project.github_repo.get_commit(sha=sha) + except github.UnknownObjectException as ex: + raise GithubAPIException(f"No git commit with id {sha} found") from ex + return GithubCommit(commit, project) + + +class GithubCommitChanges(CommitChanges): + commit: "ogr_github.GithubCommit" + + @property + def files(self) -> Iterable[str]: + for file in self.commit._raw_commit.files: + yield file.filename + + @property + def patch(self) -> bytes: + patch_url = f"{self.commit._raw_commit.html_url}.patch" + response = requests.get(patch_url) + + if not response.ok: + cls = OgrNetworkError if response.status_code >= 500 else GithubAPIException + raise cls( + f"Couldn't get patch from {patch_url} because {response.reason}.", + ) + + return response.content + + @property + def diff_url(self) -> str: + return f"{self.commit._raw_commit.html_url}.diff" diff --git a/ogr/services/github/project.py b/ogr/services/github/project.py index 378e7904b..6e1b19160 100644 --- a/ogr/services/github/project.py +++ b/ogr/services/github/project.py @@ -17,6 +17,7 @@ CommitComment, CommitFlag, CommitStatus, + GitCommit, GitTag, Issue, IssueStatus, @@ -35,6 +36,7 @@ GithubCheckRunStatus, ) from ogr.services.github.comments import GithubCommitComment +from ogr.services.github.commit import GithubCommit from ogr.services.github.flag import GithubCommitFlag from ogr.services.github.issue import GithubIssue from ogr.services.github.pull_request import GithubPullRequest @@ -301,6 +303,10 @@ def get_pr_list(self, status: PRStatus = PRStatus.open) -> list[PullRequest]: def get_pr(self, pr_id: int) -> PullRequest: pass + @indirect(GithubCommit.get) + def get_commit(self, sha: str) -> GitCommit: + pass + def get_sha_from_tag(self, tag_name: str) -> str: # TODO: This is ugly. Can we do it better? all_tags = self.github_repo.get_tags() diff --git a/ogr/services/github/pull_request.py b/ogr/services/github/pull_request.py index 0d778efaa..ed4ebc59a 100644 --- a/ogr/services/github/pull_request.py +++ b/ogr/services/github/pull_request.py @@ -15,6 +15,7 @@ from github.Repository import Repository as _GithubRepository from ogr.abstract import MergeCommitStatus, PRComment, PRLabel, PRStatus, PullRequest +from ogr.abstract.pull_request import PullRequestChanges from ogr.exceptions import GithubAPIException, OgrNetworkError from ogr.services import github as ogr_github from ogr.services.base import BasePullRequest @@ -28,6 +29,7 @@ class GithubPullRequest(BasePullRequest): _raw_pr: _GithubPullRequest _target_project: "ogr_github.GithubProject" _source_project: "ogr_github.GithubProject" = None + _changes: "GithubPullRequestChanges" = None @property def title(self) -> str: @@ -83,6 +85,12 @@ def labels(self) -> list[PRLabel]: GithubPRLabel(raw_label, self) for raw_label in self._raw_pr.get_labels() ] + @property + def changes(self) -> "GithubPullRequestChanges": + if not self._changes: + self._changes = GithubPullRequestChanges(self) + return self._changes + @property def diff_url(self) -> str: return f"{self._raw_pr.html_url}/files" @@ -268,3 +276,29 @@ def add_label(self, *labels: str) -> None: def get_comment(self, comment_id: int) -> PRComment: return GithubPRComment(self._raw_pr.get_issue_comment(comment_id)) + + +class GithubPullRequestChanges(PullRequestChanges): + pull_request: "ogr_github.GithubPullRequest" + + @property + def files(self) -> Iterable[str]: + for file in self.pull_request._raw_pr.get_files(): + yield file.filename + + @property + def patch(self) -> bytes: + patch_url = self.pull_request._raw_pr.patch_url + response = requests.get(patch_url) + + if not response.ok: + cls = OgrNetworkError if response.status_code >= 500 else GithubAPIException + raise cls( + f"Couldn't get patch from {patch_url} because {response.reason}.", + ) + + return response.content + + @property + def diff_url(self) -> str: + return f"{self.pull_request._raw_pr.html_url}.diff" diff --git a/tests/integration/github/test_commit.py b/tests/integration/github/test_commit.py new file mode 100644 index 000000000..1afbfe51b --- /dev/null +++ b/tests/integration/github/test_commit.py @@ -0,0 +1,37 @@ +# Copyright Contributors to the Packit project. +# SPDX-License-Identifier: MIT + +from requre.online_replacing import record_requests_for_all_methods + +from tests.integration.github.base import GithubTests + + +@record_requests_for_all_methods() +class Commit(GithubTests): + def test_get_branch_commit(self): + branch_commit = self.hello_world_project.get_commit("test-for-flock") + assert branch_commit.sha.startswith("e2282f3") + + def test_get_relative_commit(self): + main_branch_commit = self.hello_world_project.get_commit("test-for-flock^^") + assert main_branch_commit.sha.startswith("7c85553") + merge_branch_commit = self.hello_world_project.get_commit("test-for-flock^^2") + assert merge_branch_commit.sha.startswith("aa4883c") + + def test_changes(self): + commit = self.hello_world_project.get_commit("f06fed9") + changes = commit.changes + assert list(changes.files) == ["LICENSE", "README.md"] + + def test_get_prs(self): + # Commit with PR associated + commit_with_one_pr = self.hello_world_project.get_commit("0840e2d") + prs = list(commit_with_one_pr.get_prs()) + assert prs + assert len(prs) == 1 + assert prs[0].id == 556 + # Commit with no PR + commit_without_pr = self.hello_world_project.get_commit("f2c98da") + prs = list(commit_without_pr.get_prs()) + assert not prs + # No test data for commit with multiple PRs diff --git a/tests/integration/github/test_data/test_commit/Commit.test_changes.yaml b/tests/integration/github/test_data/test_commit/Commit.test_changes.yaml new file mode 100644 index 000000000..69e4d39c7 --- /dev/null +++ b/tests/integration/github/test_data/test_commit/Commit.test_changes.yaml @@ -0,0 +1,441 @@ +_requre: + DataTypes: 1 + key_strategy: StorageKeysInspectSimple + version_storage_file: 3 +requests.sessions: + send: + GET: + https://api.github.com:443/repos/packit/hello-world: + - metadata: + latency: 0.32317018508911133 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.commit + - ogr.services.github.project + - github.MainClass + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + allow_forking: true + archive_url: https://api.github.com/repos/packit/hello-world/{archive_format}{/ref} + archived: false + assignees_url: https://api.github.com/repos/packit/hello-world/assignees{/user} + blobs_url: https://api.github.com/repos/packit/hello-world/git/blobs{/sha} + branches_url: https://api.github.com/repos/packit/hello-world/branches{/branch} + clone_url: https://github.com/packit/hello-world.git + collaborators_url: https://api.github.com/repos/packit/hello-world/collaborators{/collaborator} + comments_url: https://api.github.com/repos/packit/hello-world/comments{/number} + commits_url: https://api.github.com/repos/packit/hello-world/commits{/sha} + compare_url: https://api.github.com/repos/packit/hello-world/compare/{base}...{head} + contents_url: https://api.github.com/repos/packit/hello-world/contents/{+path} + contributors_url: https://api.github.com/repos/packit/hello-world/contributors + created_at: '2019-05-02T18:54:46Z' + custom_properties: {} + default_branch: main + deployments_url: https://api.github.com/repos/packit/hello-world/deployments + description: The most progresive command-line tool in the world. + disabled: false + downloads_url: https://api.github.com/repos/packit/hello-world/downloads + events_url: https://api.github.com/repos/packit/hello-world/events + fork: false + forks: 23 + forks_count: 23 + forks_url: https://api.github.com/repos/packit/hello-world/forks + full_name: packit/hello-world + git_commits_url: https://api.github.com/repos/packit/hello-world/git/commits{/sha} + git_refs_url: https://api.github.com/repos/packit/hello-world/git/refs{/sha} + git_tags_url: https://api.github.com/repos/packit/hello-world/git/tags{/sha} + git_url: git://github.com/packit/hello-world.git + has_discussions: false + has_downloads: true + has_issues: true + has_pages: false + has_projects: true + has_wiki: true + homepage: null + hooks_url: https://api.github.com/repos/packit/hello-world/hooks + html_url: https://github.com/packit/hello-world + id: 184635124 + is_template: false + issue_comment_url: https://api.github.com/repos/packit/hello-world/issues/comments{/number} + issue_events_url: https://api.github.com/repos/packit/hello-world/issues/events{/number} + issues_url: https://api.github.com/repos/packit/hello-world/issues{/number} + keys_url: https://api.github.com/repos/packit/hello-world/keys{/key_id} + labels_url: https://api.github.com/repos/packit/hello-world/labels{/name} + language: Python + languages_url: https://api.github.com/repos/packit/hello-world/languages + license: + key: mit + name: MIT License + node_id: MDc6TGljZW5zZTEz + spdx_id: MIT + url: https://api.github.com/licenses/mit + merges_url: https://api.github.com/repos/packit/hello-world/merges + milestones_url: https://api.github.com/repos/packit/hello-world/milestones{/number} + mirror_url: null + name: hello-world + network_count: 23 + node_id: MDEwOlJlcG9zaXRvcnkxODQ2MzUxMjQ= + notifications_url: https://api.github.com/repos/packit/hello-world/notifications{?since,all,participating} + open_issues: 99 + open_issues_count: 99 + organization: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + owner: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + permissions: + admin: false + maintain: false + pull: true + push: false + triage: false + private: false + pulls_url: https://api.github.com/repos/packit/hello-world/pulls{/number} + pushed_at: '2025-05-23T04:48:00Z' + releases_url: https://api.github.com/repos/packit/hello-world/releases{/id} + size: 224 + ssh_url: git@github.com:packit/hello-world.git + stargazers_count: 4 + stargazers_url: https://api.github.com/repos/packit/hello-world/stargazers + statuses_url: https://api.github.com/repos/packit/hello-world/statuses/{sha} + subscribers_count: 5 + subscribers_url: https://api.github.com/repos/packit/hello-world/subscribers + subscription_url: https://api.github.com/repos/packit/hello-world/subscription + svn_url: https://github.com/packit/hello-world + tags_url: https://api.github.com/repos/packit/hello-world/tags + teams_url: https://api.github.com/repos/packit/hello-world/teams + topics: [] + trees_url: https://api.github.com/repos/packit/hello-world/git/trees{/sha} + updated_at: '2023-01-31T17:16:23Z' + url: https://api.github.com/repos/packit/hello-world + visibility: public + watchers: 4 + watchers_count: 4 + web_commit_signoff_required: false + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Tue, 31 Jan 2023 17:16:23 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '154' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: metadata=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 + https://api.github.com:443/repos/packit/hello-world/commits/f06fed9: + - metadata: + latency: 0.3590705394744873 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.commit + - github.Repository + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + author: + avatar_url: https://avatars.githubusercontent.com/u/1662493?v=4 + events_url: https://api.github.com/users/TomasTomecek/events{/privacy} + followers_url: https://api.github.com/users/TomasTomecek/followers + following_url: https://api.github.com/users/TomasTomecek/following{/other_user} + gists_url: https://api.github.com/users/TomasTomecek/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/TomasTomecek + id: 1662493 + login: TomasTomecek + node_id: MDQ6VXNlcjE2NjI0OTM= + organizations_url: https://api.github.com/users/TomasTomecek/orgs + received_events_url: https://api.github.com/users/TomasTomecek/received_events + repos_url: https://api.github.com/users/TomasTomecek/repos + site_admin: false + starred_url: https://api.github.com/users/TomasTomecek/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/TomasTomecek/subscriptions + type: User + url: https://api.github.com/users/TomasTomecek + user_view_type: public + comments_url: https://api.github.com/repos/packit/hello-world/commits/f06fed9216c5cda12cb9284c0b9f709aa948d513/comments + commit: + author: + date: '2019-05-02T18:54:47Z' + email: tomas@tomecek.net + name: Tomas Tomecek + comment_count: 0 + committer: + date: '2019-05-02T18:54:47Z' + email: noreply@github.com + name: GitHub + message: Initial commit + tree: + sha: 9455ecd787e32c53583cbb339c3d62b04c177507 + url: https://api.github.com/repos/packit/hello-world/git/trees/9455ecd787e32c53583cbb339c3d62b04c177507 + url: https://api.github.com/repos/packit/hello-world/git/commits/f06fed9216c5cda12cb9284c0b9f709aa948d513 + verification: + payload: 'tree 9455ecd787e32c53583cbb339c3d62b04c177507 + + author Tomas Tomecek 1556823287 +0200 + + committer GitHub 1556823287 +0200 + + + Initial commit' + reason: valid + signature: '-----BEGIN PGP SIGNATURE----- + + + wsBcBAABCAAQBQJcyzz3CRBK7hj4Ov3rIwAAdHIIAFdaeMfJH8VFJvV8E1Agf8WK + + nfcc864o2rhCbMn7YCzWE3XvwHfbkOFeiiXOi3Dd8NzsHm2WR6VCK4NQqnizBAlx + + x8u2hhtVI+x1FsyVWtAsx8jyC9m0MdJ0biuhE5TsNNq+WJn0/Fd198CLzSdDKJmM + + nidW/Xs4BdozOkfdKBHHIG3BNnkHqhiGCK3kQEOBZipuSecLvZMhyo9T1aCrYmHn + + ENOt1hGcDAKZg8vCwT+klHy3WJZvkOaCF+LpN7Y196pwbIUXX65WbGtVr6IIZGiW + + 9H+jdavf3zmbmpPbagi/MLifYuqnXppCSa67UNpIg/d70S0EHozFXGIHN7BihuM= + + =dyFI + + -----END PGP SIGNATURE----- + + ' + verified: true + verified_at: '2024-11-06T04:04:00Z' + committer: + avatar_url: https://avatars.githubusercontent.com/u/19864447?v=4 + events_url: https://api.github.com/users/web-flow/events{/privacy} + followers_url: https://api.github.com/users/web-flow/followers + following_url: https://api.github.com/users/web-flow/following{/other_user} + gists_url: https://api.github.com/users/web-flow/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/web-flow + id: 19864447 + login: web-flow + node_id: MDQ6VXNlcjE5ODY0NDQ3 + organizations_url: https://api.github.com/users/web-flow/orgs + received_events_url: https://api.github.com/users/web-flow/received_events + repos_url: https://api.github.com/users/web-flow/repos + site_admin: false + starred_url: https://api.github.com/users/web-flow/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/web-flow/subscriptions + type: User + url: https://api.github.com/users/web-flow + user_view_type: public + files: + - additions: 21 + blob_url: https://github.com/packit/hello-world/blob/f06fed9216c5cda12cb9284c0b9f709aa948d513/LICENSE + changes: 21 + contents_url: https://api.github.com/repos/packit/hello-world/contents/LICENSE?ref=f06fed9216c5cda12cb9284c0b9f709aa948d513 + deletions: 0 + filename: LICENSE + patch: '@@ -0,0 +1,21 @@ + + +MIT License + + + + + +Copyright (c) 2019 Packit + + + + + +Permission is hereby granted, free of charge, to any person obtaining + a copy + + +of this software and associated documentation files (the "Software"), + to deal + + +in the Software without restriction, including without limitation + the rights + + +to use, copy, modify, merge, publish, distribute, sublicense, and/or + sell + + +copies of the Software, and to permit persons to whom the Software + is + + +furnished to do so, subject to the following conditions: + + + + + +The above copyright notice and this permission notice shall be included + in all + + +copies or substantial portions of the Software. + + + + + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + OR + + +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + + +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT + SHALL THE + + +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR + OTHER + + +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + FROM, + + +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS + IN THE + + +SOFTWARE.' + raw_url: https://github.com/packit/hello-world/raw/f06fed9216c5cda12cb9284c0b9f709aa948d513/LICENSE + sha: 5cb23a21a2a206185ec1b62429baec88b5198821 + status: added + - additions: 2 + blob_url: https://github.com/packit/hello-world/blob/f06fed9216c5cda12cb9284c0b9f709aa948d513/README.md + changes: 2 + contents_url: https://api.github.com/repos/packit/hello-world/contents/README.md?ref=f06fed9216c5cda12cb9284c0b9f709aa948d513 + deletions: 0 + filename: README.md + patch: '@@ -0,0 +1,2 @@ + + +# hello-world + + +The most progresive command-line tool in the world.' + raw_url: https://github.com/packit/hello-world/raw/f06fed9216c5cda12cb9284c0b9f709aa948d513/README.md + sha: 695f511a2aa586c6d0b0939395fb37bdcbacf687 + status: added + html_url: https://github.com/packit/hello-world/commit/f06fed9216c5cda12cb9284c0b9f709aa948d513 + node_id: MDY6Q29tbWl0MTg0NjM1MTI0OmYwNmZlZDkyMTZjNWNkYTEyY2I5Mjg0YzBiOWY3MDlhYTk0OGQ1MTM= + parents: [] + sha: f06fed9216c5cda12cb9284c0b9f709aa948d513 + stats: + additions: 23 + deletions: 0 + total: 23 + url: https://api.github.com/repos/packit/hello-world/commits/f06fed9216c5cda12cb9284c0b9f709aa948d513 + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Thu, 02 May 2019 18:54:47 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '155' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: contents=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 diff --git a/tests/integration/github/test_data/test_commit/Commit.test_get_branch_commit.yaml b/tests/integration/github/test_data/test_commit/Commit.test_get_branch_commit.yaml new file mode 100644 index 000000000..7aa4db391 --- /dev/null +++ b/tests/integration/github/test_data/test_commit/Commit.test_get_branch_commit.yaml @@ -0,0 +1,344 @@ +_requre: + DataTypes: 1 + key_strategy: StorageKeysInspectSimple + version_storage_file: 3 +requests.sessions: + send: + GET: + https://api.github.com:443/repos/packit/hello-world: + - metadata: + latency: 0.3320186138153076 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.commit + - ogr.services.github.project + - github.MainClass + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + allow_forking: true + archive_url: https://api.github.com/repos/packit/hello-world/{archive_format}{/ref} + archived: false + assignees_url: https://api.github.com/repos/packit/hello-world/assignees{/user} + blobs_url: https://api.github.com/repos/packit/hello-world/git/blobs{/sha} + branches_url: https://api.github.com/repos/packit/hello-world/branches{/branch} + clone_url: https://github.com/packit/hello-world.git + collaborators_url: https://api.github.com/repos/packit/hello-world/collaborators{/collaborator} + comments_url: https://api.github.com/repos/packit/hello-world/comments{/number} + commits_url: https://api.github.com/repos/packit/hello-world/commits{/sha} + compare_url: https://api.github.com/repos/packit/hello-world/compare/{base}...{head} + contents_url: https://api.github.com/repos/packit/hello-world/contents/{+path} + contributors_url: https://api.github.com/repos/packit/hello-world/contributors + created_at: '2019-05-02T18:54:46Z' + custom_properties: {} + default_branch: main + deployments_url: https://api.github.com/repos/packit/hello-world/deployments + description: The most progresive command-line tool in the world. + disabled: false + downloads_url: https://api.github.com/repos/packit/hello-world/downloads + events_url: https://api.github.com/repos/packit/hello-world/events + fork: false + forks: 23 + forks_count: 23 + forks_url: https://api.github.com/repos/packit/hello-world/forks + full_name: packit/hello-world + git_commits_url: https://api.github.com/repos/packit/hello-world/git/commits{/sha} + git_refs_url: https://api.github.com/repos/packit/hello-world/git/refs{/sha} + git_tags_url: https://api.github.com/repos/packit/hello-world/git/tags{/sha} + git_url: git://github.com/packit/hello-world.git + has_discussions: false + has_downloads: true + has_issues: true + has_pages: false + has_projects: true + has_wiki: true + homepage: null + hooks_url: https://api.github.com/repos/packit/hello-world/hooks + html_url: https://github.com/packit/hello-world + id: 184635124 + is_template: false + issue_comment_url: https://api.github.com/repos/packit/hello-world/issues/comments{/number} + issue_events_url: https://api.github.com/repos/packit/hello-world/issues/events{/number} + issues_url: https://api.github.com/repos/packit/hello-world/issues{/number} + keys_url: https://api.github.com/repos/packit/hello-world/keys{/key_id} + labels_url: https://api.github.com/repos/packit/hello-world/labels{/name} + language: Python + languages_url: https://api.github.com/repos/packit/hello-world/languages + license: + key: mit + name: MIT License + node_id: MDc6TGljZW5zZTEz + spdx_id: MIT + url: https://api.github.com/licenses/mit + merges_url: https://api.github.com/repos/packit/hello-world/merges + milestones_url: https://api.github.com/repos/packit/hello-world/milestones{/number} + mirror_url: null + name: hello-world + network_count: 23 + node_id: MDEwOlJlcG9zaXRvcnkxODQ2MzUxMjQ= + notifications_url: https://api.github.com/repos/packit/hello-world/notifications{?since,all,participating} + open_issues: 99 + open_issues_count: 99 + organization: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + owner: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + permissions: + admin: false + maintain: false + pull: true + push: false + triage: false + private: false + pulls_url: https://api.github.com/repos/packit/hello-world/pulls{/number} + pushed_at: '2025-05-23T04:48:00Z' + releases_url: https://api.github.com/repos/packit/hello-world/releases{/id} + size: 224 + ssh_url: git@github.com:packit/hello-world.git + stargazers_count: 4 + stargazers_url: https://api.github.com/repos/packit/hello-world/stargazers + statuses_url: https://api.github.com/repos/packit/hello-world/statuses/{sha} + subscribers_count: 5 + subscribers_url: https://api.github.com/repos/packit/hello-world/subscribers + subscription_url: https://api.github.com/repos/packit/hello-world/subscription + svn_url: https://github.com/packit/hello-world + tags_url: https://api.github.com/repos/packit/hello-world/tags + teams_url: https://api.github.com/repos/packit/hello-world/teams + topics: [] + trees_url: https://api.github.com/repos/packit/hello-world/git/trees{/sha} + updated_at: '2023-01-31T17:16:23Z' + url: https://api.github.com/repos/packit/hello-world + visibility: public + watchers: 4 + watchers_count: 4 + web_commit_signoff_required: false + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Tue, 31 Jan 2023 17:16:23 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '156' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: metadata=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 + https://api.github.com:443/repos/packit/hello-world/commits/test-for-flock: + - metadata: + latency: 0.2596895694732666 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.commit + - github.Repository + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + author: + avatar_url: https://avatars.githubusercontent.com/u/633969?v=4 + events_url: https://api.github.com/users/thrix/events{/privacy} + followers_url: https://api.github.com/users/thrix/followers + following_url: https://api.github.com/users/thrix/following{/other_user} + gists_url: https://api.github.com/users/thrix/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/thrix + id: 633969 + login: thrix + node_id: MDQ6VXNlcjYzMzk2OQ== + organizations_url: https://api.github.com/users/thrix/orgs + received_events_url: https://api.github.com/users/thrix/received_events + repos_url: https://api.github.com/users/thrix/repos + site_admin: false + starred_url: https://api.github.com/users/thrix/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/thrix/subscriptions + type: User + url: https://api.github.com/users/thrix + user_view_type: public + comments_url: https://api.github.com/repos/packit/hello-world/commits/e2282f3083a5e11e76a0a4a2d5de7c7f8afdecd0/comments + commit: + author: + date: '2019-08-08T23:31:40Z' + email: mvadkert@redhat.com + name: Miroslav Vadkerti + comment_count: 0 + committer: + date: '2019-08-08T23:31:40Z' + email: mvadkert@redhat.com + name: Miroslav Vadkerti + message: 'Test for flock + + + Signed-off-by: Miroslav Vadkerti ' + tree: + sha: 243e34c0df9eb8c61045d17f0a06abc4202ca8b4 + url: https://api.github.com/repos/packit/hello-world/git/trees/243e34c0df9eb8c61045d17f0a06abc4202ca8b4 + url: https://api.github.com/repos/packit/hello-world/git/commits/e2282f3083a5e11e76a0a4a2d5de7c7f8afdecd0 + verification: + payload: null + reason: unsigned + signature: null + verified: false + verified_at: null + committer: + avatar_url: https://avatars.githubusercontent.com/u/633969?v=4 + events_url: https://api.github.com/users/thrix/events{/privacy} + followers_url: https://api.github.com/users/thrix/followers + following_url: https://api.github.com/users/thrix/following{/other_user} + gists_url: https://api.github.com/users/thrix/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/thrix + id: 633969 + login: thrix + node_id: MDQ6VXNlcjYzMzk2OQ== + organizations_url: https://api.github.com/users/thrix/orgs + received_events_url: https://api.github.com/users/thrix/received_events + repos_url: https://api.github.com/users/thrix/repos + site_admin: false + starred_url: https://api.github.com/users/thrix/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/thrix/subscriptions + type: User + url: https://api.github.com/users/thrix + user_view_type: public + files: [] + html_url: https://github.com/packit/hello-world/commit/e2282f3083a5e11e76a0a4a2d5de7c7f8afdecd0 + node_id: MDY6Q29tbWl0MTg0NjM1MTI0OmUyMjgyZjMwODNhNWUxMWU3NmEwYTRhMmQ1ZGU3YzdmOGFmZGVjZDA= + parents: + - html_url: https://github.com/packit/hello-world/commit/bc88c7c257b74d3bf8a7d3e21b2baf3f342dd52f + sha: bc88c7c257b74d3bf8a7d3e21b2baf3f342dd52f + url: https://api.github.com/repos/packit/hello-world/commits/bc88c7c257b74d3bf8a7d3e21b2baf3f342dd52f + sha: e2282f3083a5e11e76a0a4a2d5de7c7f8afdecd0 + stats: + additions: 0 + deletions: 0 + total: 0 + url: https://api.github.com/repos/packit/hello-world/commits/e2282f3083a5e11e76a0a4a2d5de7c7f8afdecd0 + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Thu, 08 Aug 2019 23:31:40 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '157' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: contents=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 diff --git a/tests/integration/github/test_data/test_commit/Commit.test_get_prs.yaml b/tests/integration/github/test_data/test_commit/Commit.test_get_prs.yaml new file mode 100644 index 000000000..fca1c5f6a --- /dev/null +++ b/tests/integration/github/test_data/test_commit/Commit.test_get_prs.yaml @@ -0,0 +1,986 @@ +_requre: + DataTypes: 1 + key_strategy: StorageKeysInspectSimple + version_storage_file: 3 +requests.sessions: + send: + GET: + https://api.github.com:443/repos/packit/hello-world: + - metadata: + latency: 0.32793116569519043 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.commit + - ogr.services.github.project + - github.MainClass + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + allow_forking: true + archive_url: https://api.github.com/repos/packit/hello-world/{archive_format}{/ref} + archived: false + assignees_url: https://api.github.com/repos/packit/hello-world/assignees{/user} + blobs_url: https://api.github.com/repos/packit/hello-world/git/blobs{/sha} + branches_url: https://api.github.com/repos/packit/hello-world/branches{/branch} + clone_url: https://github.com/packit/hello-world.git + collaborators_url: https://api.github.com/repos/packit/hello-world/collaborators{/collaborator} + comments_url: https://api.github.com/repos/packit/hello-world/comments{/number} + commits_url: https://api.github.com/repos/packit/hello-world/commits{/sha} + compare_url: https://api.github.com/repos/packit/hello-world/compare/{base}...{head} + contents_url: https://api.github.com/repos/packit/hello-world/contents/{+path} + contributors_url: https://api.github.com/repos/packit/hello-world/contributors + created_at: '2019-05-02T18:54:46Z' + custom_properties: {} + default_branch: main + deployments_url: https://api.github.com/repos/packit/hello-world/deployments + description: The most progresive command-line tool in the world. + disabled: false + downloads_url: https://api.github.com/repos/packit/hello-world/downloads + events_url: https://api.github.com/repos/packit/hello-world/events + fork: false + forks: 23 + forks_count: 23 + forks_url: https://api.github.com/repos/packit/hello-world/forks + full_name: packit/hello-world + git_commits_url: https://api.github.com/repos/packit/hello-world/git/commits{/sha} + git_refs_url: https://api.github.com/repos/packit/hello-world/git/refs{/sha} + git_tags_url: https://api.github.com/repos/packit/hello-world/git/tags{/sha} + git_url: git://github.com/packit/hello-world.git + has_discussions: false + has_downloads: true + has_issues: true + has_pages: false + has_projects: true + has_wiki: true + homepage: null + hooks_url: https://api.github.com/repos/packit/hello-world/hooks + html_url: https://github.com/packit/hello-world + id: 184635124 + is_template: false + issue_comment_url: https://api.github.com/repos/packit/hello-world/issues/comments{/number} + issue_events_url: https://api.github.com/repos/packit/hello-world/issues/events{/number} + issues_url: https://api.github.com/repos/packit/hello-world/issues{/number} + keys_url: https://api.github.com/repos/packit/hello-world/keys{/key_id} + labels_url: https://api.github.com/repos/packit/hello-world/labels{/name} + language: Python + languages_url: https://api.github.com/repos/packit/hello-world/languages + license: + key: mit + name: MIT License + node_id: MDc6TGljZW5zZTEz + spdx_id: MIT + url: https://api.github.com/licenses/mit + merges_url: https://api.github.com/repos/packit/hello-world/merges + milestones_url: https://api.github.com/repos/packit/hello-world/milestones{/number} + mirror_url: null + name: hello-world + network_count: 23 + node_id: MDEwOlJlcG9zaXRvcnkxODQ2MzUxMjQ= + notifications_url: https://api.github.com/repos/packit/hello-world/notifications{?since,all,participating} + open_issues: 99 + open_issues_count: 99 + organization: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + owner: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + permissions: + admin: false + maintain: false + pull: true + push: false + triage: false + private: false + pulls_url: https://api.github.com/repos/packit/hello-world/pulls{/number} + pushed_at: '2025-05-28T04:58:49Z' + releases_url: https://api.github.com/repos/packit/hello-world/releases{/id} + size: 226 + ssh_url: git@github.com:packit/hello-world.git + stargazers_count: 4 + stargazers_url: https://api.github.com/repos/packit/hello-world/stargazers + statuses_url: https://api.github.com/repos/packit/hello-world/statuses/{sha} + subscribers_count: 5 + subscribers_url: https://api.github.com/repos/packit/hello-world/subscribers + subscription_url: https://api.github.com/repos/packit/hello-world/subscription + svn_url: https://github.com/packit/hello-world + tags_url: https://api.github.com/repos/packit/hello-world/tags + teams_url: https://api.github.com/repos/packit/hello-world/teams + topics: [] + trees_url: https://api.github.com/repos/packit/hello-world/git/trees{/sha} + updated_at: '2023-01-31T17:16:23Z' + url: https://api.github.com/repos/packit/hello-world + visibility: public + watchers: 4 + watchers_count: 4 + web_commit_signoff_required: false + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Tue, 31 Jan 2023 17:16:23 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '194' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: metadata=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 + https://api.github.com:443/repos/packit/hello-world/commits/0840e2d: + - metadata: + latency: 0.32741880416870117 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.commit + - github.Repository + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + author: + avatar_url: https://avatars.githubusercontent.com/u/288686?v=4 + events_url: https://api.github.com/users/jpopelka/events{/privacy} + followers_url: https://api.github.com/users/jpopelka/followers + following_url: https://api.github.com/users/jpopelka/following{/other_user} + gists_url: https://api.github.com/users/jpopelka/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/jpopelka + id: 288686 + login: jpopelka + node_id: MDQ6VXNlcjI4ODY4Ng== + organizations_url: https://api.github.com/users/jpopelka/orgs + received_events_url: https://api.github.com/users/jpopelka/received_events + repos_url: https://api.github.com/users/jpopelka/repos + site_admin: false + starred_url: https://api.github.com/users/jpopelka/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/jpopelka/subscriptions + type: User + url: https://api.github.com/users/jpopelka + user_view_type: public + comments_url: https://api.github.com/repos/packit/hello-world/commits/0840e2dac94668176ceb6ecfc0f14e2b95118e75/comments + commit: + author: + date: '2021-11-30T09:33:52Z' + email: jpopelka@redhat.com + name: Jiri Popelka + comment_count: 0 + committer: + date: '2021-11-30T09:33:52Z' + email: noreply@github.com + name: GitHub + message: 'Merge pull request #556 from jpopelka/dist_git_branches + + + dist-git-branch has been renamed dist_git_branches' + tree: + sha: 2dd2805625d9e9970847fb3bd8f9582825ae7317 + url: https://api.github.com/repos/packit/hello-world/git/trees/2dd2805625d9e9970847fb3bd8f9582825ae7317 + url: https://api.github.com/repos/packit/hello-world/git/commits/0840e2dac94668176ceb6ecfc0f14e2b95118e75 + verification: + payload: 'tree 2dd2805625d9e9970847fb3bd8f9582825ae7317 + + parent 15b64f2eb671d05dfb5773e544156aa570a50f96 + + parent 622a20fbd42ca7a70a6d65321b45d556090a13c0 + + author Jiri Popelka 1638264832 +0100 + + committer GitHub 1638264832 +0100 + + + Merge pull request #556 from jpopelka/dist_git_branches + + + dist-git-branch has been renamed dist_git_branches' + reason: valid + signature: '-----BEGIN PGP SIGNATURE----- + + + wsBcBAABCAAQBQJhpfAACRBK7hj4Ov3rIwAAlC0IAByAm56tlftqiU7NiD15UkEU + + dPpqDd573kfr7cHksOLYO5R2Bbf5Bpza/nc5pQwwA7VL3YHkN2uqstt+EMQkKlsn + + 1+L5pqQz11EGMENDGlGS8vOuZRaaHvUjCaMgScCkKYpCgMSFbOuR1cIJe+eOj573 + + m0rRReWJ4P/wAFN99xOIVIfqFsISNyo/vBTreJz4ZMiusR307H3gbJXjNl+5drTD + + mMyJ0odSXLiaLD2MiHensEZKSdOZFmHRDYdIbMIpLCpyf13loWH1H4X/n4GwPAfZ + + dWINKuAAU5SSZlM475uxH7bttV1U+72Uprvc6AFCQopTmUSpjdKa6WrlmMbsa8U= + + =7kes + + -----END PGP SIGNATURE----- + + ' + verified: true + verified_at: '2024-01-16T19:59:59Z' + committer: + avatar_url: https://avatars.githubusercontent.com/u/19864447?v=4 + events_url: https://api.github.com/users/web-flow/events{/privacy} + followers_url: https://api.github.com/users/web-flow/followers + following_url: https://api.github.com/users/web-flow/following{/other_user} + gists_url: https://api.github.com/users/web-flow/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/web-flow + id: 19864447 + login: web-flow + node_id: MDQ6VXNlcjE5ODY0NDQ3 + organizations_url: https://api.github.com/users/web-flow/orgs + received_events_url: https://api.github.com/users/web-flow/received_events + repos_url: https://api.github.com/users/web-flow/repos + site_admin: false + starred_url: https://api.github.com/users/web-flow/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/web-flow/subscriptions + type: User + url: https://api.github.com/users/web-flow + user_view_type: public + files: + - additions: 2 + blob_url: https://github.com/packit/hello-world/blob/0840e2dac94668176ceb6ecfc0f14e2b95118e75/.packit.yaml + changes: 3 + contents_url: https://api.github.com/repos/packit/hello-world/contents/.packit.yaml?ref=0840e2dac94668176ceb6ecfc0f14e2b95118e75 + deletions: 1 + filename: .packit.yaml + patch: "@@ -39,4 +39,5 @@ jobs:\n - job: propose_downstream\n trigger:\ + \ release\n metadata:\n- dist-git-branch: fedora-all\n+ dist_git_branches:\n\ + + - fedora-all" + raw_url: https://github.com/packit/hello-world/raw/0840e2dac94668176ceb6ecfc0f14e2b95118e75/.packit.yaml + sha: 2398a301b53810364acff591ad82eb50e23c4e7c + status: modified + html_url: https://github.com/packit/hello-world/commit/0840e2dac94668176ceb6ecfc0f14e2b95118e75 + node_id: C_kwDOCwFO9NoAKDA4NDBlMmRhYzk0NjY4MTc2Y2ViNmVjZmMwZjE0ZTJiOTUxMThlNzU + parents: + - html_url: https://github.com/packit/hello-world/commit/15b64f2eb671d05dfb5773e544156aa570a50f96 + sha: 15b64f2eb671d05dfb5773e544156aa570a50f96 + url: https://api.github.com/repos/packit/hello-world/commits/15b64f2eb671d05dfb5773e544156aa570a50f96 + - html_url: https://github.com/packit/hello-world/commit/622a20fbd42ca7a70a6d65321b45d556090a13c0 + sha: 622a20fbd42ca7a70a6d65321b45d556090a13c0 + url: https://api.github.com/repos/packit/hello-world/commits/622a20fbd42ca7a70a6d65321b45d556090a13c0 + sha: 0840e2dac94668176ceb6ecfc0f14e2b95118e75 + stats: + additions: 2 + deletions: 1 + total: 3 + url: https://api.github.com/repos/packit/hello-world/commits/0840e2dac94668176ceb6ecfc0f14e2b95118e75 + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Tue, 30 Nov 2021 09:33:52 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '195' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: contents=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 + https://api.github.com:443/repos/packit/hello-world/commits/0840e2dac94668176ceb6ecfc0f14e2b95118e75/pulls: + - metadata: + latency: 0.7519180774688721 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.services.github.commit + - github.PaginatedList + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + - _links: + comments: + href: https://api.github.com/repos/packit/hello-world/issues/556/comments + commits: + href: https://api.github.com/repos/packit/hello-world/pulls/556/commits + html: + href: https://github.com/packit/hello-world/pull/556 + issue: + href: https://api.github.com/repos/packit/hello-world/issues/556 + review_comment: + href: https://api.github.com/repos/packit/hello-world/pulls/comments{/number} + review_comments: + href: https://api.github.com/repos/packit/hello-world/pulls/556/comments + self: + href: https://api.github.com/repos/packit/hello-world/pulls/556 + statuses: + href: https://api.github.com/repos/packit/hello-world/statuses/622a20fbd42ca7a70a6d65321b45d556090a13c0 + active_lock_reason: null + assignee: null + assignees: [] + author_association: MEMBER + auto_merge: null + base: + label: packit:main + ref: main + repo: + allow_forking: true + archive_url: https://api.github.com/repos/packit/hello-world/{archive_format}{/ref} + archived: false + assignees_url: https://api.github.com/repos/packit/hello-world/assignees{/user} + blobs_url: https://api.github.com/repos/packit/hello-world/git/blobs{/sha} + branches_url: https://api.github.com/repos/packit/hello-world/branches{/branch} + clone_url: https://github.com/packit/hello-world.git + collaborators_url: https://api.github.com/repos/packit/hello-world/collaborators{/collaborator} + comments_url: https://api.github.com/repos/packit/hello-world/comments{/number} + commits_url: https://api.github.com/repos/packit/hello-world/commits{/sha} + compare_url: https://api.github.com/repos/packit/hello-world/compare/{base}...{head} + contents_url: https://api.github.com/repos/packit/hello-world/contents/{+path} + contributors_url: https://api.github.com/repos/packit/hello-world/contributors + created_at: '2019-05-02T18:54:46Z' + default_branch: main + deployments_url: https://api.github.com/repos/packit/hello-world/deployments + description: The most progresive command-line tool in the world. + disabled: false + downloads_url: https://api.github.com/repos/packit/hello-world/downloads + events_url: https://api.github.com/repos/packit/hello-world/events + fork: false + forks: 23 + forks_count: 23 + forks_url: https://api.github.com/repos/packit/hello-world/forks + full_name: packit/hello-world + git_commits_url: https://api.github.com/repos/packit/hello-world/git/commits{/sha} + git_refs_url: https://api.github.com/repos/packit/hello-world/git/refs{/sha} + git_tags_url: https://api.github.com/repos/packit/hello-world/git/tags{/sha} + git_url: git://github.com/packit/hello-world.git + has_discussions: false + has_downloads: true + has_issues: true + has_pages: false + has_projects: true + has_wiki: true + homepage: null + hooks_url: https://api.github.com/repos/packit/hello-world/hooks + html_url: https://github.com/packit/hello-world + id: 184635124 + is_template: false + issue_comment_url: https://api.github.com/repos/packit/hello-world/issues/comments{/number} + issue_events_url: https://api.github.com/repos/packit/hello-world/issues/events{/number} + issues_url: https://api.github.com/repos/packit/hello-world/issues{/number} + keys_url: https://api.github.com/repos/packit/hello-world/keys{/key_id} + labels_url: https://api.github.com/repos/packit/hello-world/labels{/name} + language: Python + languages_url: https://api.github.com/repos/packit/hello-world/languages + license: + key: mit + name: MIT License + node_id: MDc6TGljZW5zZTEz + spdx_id: MIT + url: https://api.github.com/licenses/mit + merges_url: https://api.github.com/repos/packit/hello-world/merges + milestones_url: https://api.github.com/repos/packit/hello-world/milestones{/number} + mirror_url: null + name: hello-world + node_id: MDEwOlJlcG9zaXRvcnkxODQ2MzUxMjQ= + notifications_url: https://api.github.com/repos/packit/hello-world/notifications{?since,all,participating} + open_issues: 99 + open_issues_count: 99 + owner: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + private: false + pulls_url: https://api.github.com/repos/packit/hello-world/pulls{/number} + pushed_at: '2025-05-28T04:58:49Z' + releases_url: https://api.github.com/repos/packit/hello-world/releases{/id} + size: 226 + ssh_url: git@github.com:packit/hello-world.git + stargazers_count: 4 + stargazers_url: https://api.github.com/repos/packit/hello-world/stargazers + statuses_url: https://api.github.com/repos/packit/hello-world/statuses/{sha} + subscribers_url: https://api.github.com/repos/packit/hello-world/subscribers + subscription_url: https://api.github.com/repos/packit/hello-world/subscription + svn_url: https://github.com/packit/hello-world + tags_url: https://api.github.com/repos/packit/hello-world/tags + teams_url: https://api.github.com/repos/packit/hello-world/teams + topics: [] + trees_url: https://api.github.com/repos/packit/hello-world/git/trees{/sha} + updated_at: '2023-01-31T17:16:23Z' + url: https://api.github.com/repos/packit/hello-world + visibility: public + watchers: 4 + watchers_count: 4 + web_commit_signoff_required: false + sha: 15b64f2eb671d05dfb5773e544156aa570a50f96 + user: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + body: null + closed_at: '2021-11-30T09:33:52Z' + comments_url: https://api.github.com/repos/packit/hello-world/issues/556/comments + commits_url: https://api.github.com/repos/packit/hello-world/pulls/556/commits + created_at: '2021-11-27T09:47:07Z' + diff_url: https://github.com/packit/hello-world/pull/556.diff + draft: false + head: + label: jpopelka:dist_git_branches + ref: dist_git_branches + repo: + allow_forking: true + archive_url: https://api.github.com/repos/jpopelka/hello-world/{archive_format}{/ref} + archived: false + assignees_url: https://api.github.com/repos/jpopelka/hello-world/assignees{/user} + blobs_url: https://api.github.com/repos/jpopelka/hello-world/git/blobs{/sha} + branches_url: https://api.github.com/repos/jpopelka/hello-world/branches{/branch} + clone_url: https://github.com/jpopelka/hello-world.git + collaborators_url: https://api.github.com/repos/jpopelka/hello-world/collaborators{/collaborator} + comments_url: https://api.github.com/repos/jpopelka/hello-world/comments{/number} + commits_url: https://api.github.com/repos/jpopelka/hello-world/commits{/sha} + compare_url: https://api.github.com/repos/jpopelka/hello-world/compare/{base}...{head} + contents_url: https://api.github.com/repos/jpopelka/hello-world/contents/{+path} + contributors_url: https://api.github.com/repos/jpopelka/hello-world/contributors + created_at: '2019-08-29T12:29:57Z' + default_branch: main + deployments_url: https://api.github.com/repos/jpopelka/hello-world/deployments + description: The most progresive command-line tool in the world. + disabled: false + downloads_url: https://api.github.com/repos/jpopelka/hello-world/downloads + events_url: https://api.github.com/repos/jpopelka/hello-world/events + fork: true + forks: 0 + forks_count: 0 + forks_url: https://api.github.com/repos/jpopelka/hello-world/forks + full_name: jpopelka/hello-world + git_commits_url: https://api.github.com/repos/jpopelka/hello-world/git/commits{/sha} + git_refs_url: https://api.github.com/repos/jpopelka/hello-world/git/refs{/sha} + git_tags_url: https://api.github.com/repos/jpopelka/hello-world/git/tags{/sha} + git_url: git://github.com/jpopelka/hello-world.git + has_discussions: false + has_downloads: true + has_issues: false + has_pages: false + has_projects: true + has_wiki: true + homepage: null + hooks_url: https://api.github.com/repos/jpopelka/hello-world/hooks + html_url: https://github.com/jpopelka/hello-world + id: 205159136 + is_template: false + issue_comment_url: https://api.github.com/repos/jpopelka/hello-world/issues/comments{/number} + issue_events_url: https://api.github.com/repos/jpopelka/hello-world/issues/events{/number} + issues_url: https://api.github.com/repos/jpopelka/hello-world/issues{/number} + keys_url: https://api.github.com/repos/jpopelka/hello-world/keys{/key_id} + labels_url: https://api.github.com/repos/jpopelka/hello-world/labels{/name} + language: Python + languages_url: https://api.github.com/repos/jpopelka/hello-world/languages + license: + key: mit + name: MIT License + node_id: MDc6TGljZW5zZTEz + spdx_id: MIT + url: https://api.github.com/licenses/mit + merges_url: https://api.github.com/repos/jpopelka/hello-world/merges + milestones_url: https://api.github.com/repos/jpopelka/hello-world/milestones{/number} + mirror_url: null + name: hello-world + node_id: MDEwOlJlcG9zaXRvcnkyMDUxNTkxMzY= + notifications_url: https://api.github.com/repos/jpopelka/hello-world/notifications{?since,all,participating} + open_issues: 1 + open_issues_count: 1 + owner: + avatar_url: https://avatars.githubusercontent.com/u/288686?v=4 + events_url: https://api.github.com/users/jpopelka/events{/privacy} + followers_url: https://api.github.com/users/jpopelka/followers + following_url: https://api.github.com/users/jpopelka/following{/other_user} + gists_url: https://api.github.com/users/jpopelka/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/jpopelka + id: 288686 + login: jpopelka + node_id: MDQ6VXNlcjI4ODY4Ng== + organizations_url: https://api.github.com/users/jpopelka/orgs + received_events_url: https://api.github.com/users/jpopelka/received_events + repos_url: https://api.github.com/users/jpopelka/repos + site_admin: false + starred_url: https://api.github.com/users/jpopelka/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/jpopelka/subscriptions + type: User + url: https://api.github.com/users/jpopelka + user_view_type: public + private: false + pulls_url: https://api.github.com/repos/jpopelka/hello-world/pulls{/number} + pushed_at: '2021-11-30T16:26:17Z' + releases_url: https://api.github.com/repos/jpopelka/hello-world/releases{/id} + size: 29 + ssh_url: git@github.com:jpopelka/hello-world.git + stargazers_count: 0 + stargazers_url: https://api.github.com/repos/jpopelka/hello-world/stargazers + statuses_url: https://api.github.com/repos/jpopelka/hello-world/statuses/{sha} + subscribers_url: https://api.github.com/repos/jpopelka/hello-world/subscribers + subscription_url: https://api.github.com/repos/jpopelka/hello-world/subscription + svn_url: https://github.com/jpopelka/hello-world + tags_url: https://api.github.com/repos/jpopelka/hello-world/tags + teams_url: https://api.github.com/repos/jpopelka/hello-world/teams + topics: [] + trees_url: https://api.github.com/repos/jpopelka/hello-world/git/trees{/sha} + updated_at: '2021-11-30T16:26:20Z' + url: https://api.github.com/repos/jpopelka/hello-world + visibility: public + watchers: 0 + watchers_count: 0 + web_commit_signoff_required: false + sha: 622a20fbd42ca7a70a6d65321b45d556090a13c0 + user: + avatar_url: https://avatars.githubusercontent.com/u/288686?v=4 + events_url: https://api.github.com/users/jpopelka/events{/privacy} + followers_url: https://api.github.com/users/jpopelka/followers + following_url: https://api.github.com/users/jpopelka/following{/other_user} + gists_url: https://api.github.com/users/jpopelka/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/jpopelka + id: 288686 + login: jpopelka + node_id: MDQ6VXNlcjI4ODY4Ng== + organizations_url: https://api.github.com/users/jpopelka/orgs + received_events_url: https://api.github.com/users/jpopelka/received_events + repos_url: https://api.github.com/users/jpopelka/repos + site_admin: false + starred_url: https://api.github.com/users/jpopelka/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/jpopelka/subscriptions + type: User + url: https://api.github.com/users/jpopelka + user_view_type: public + html_url: https://github.com/packit/hello-world/pull/556 + id: 789905241 + issue_url: https://api.github.com/repos/packit/hello-world/issues/556 + labels: [] + locked: false + merge_commit_sha: 0840e2dac94668176ceb6ecfc0f14e2b95118e75 + merged_at: '2021-11-30T09:33:52Z' + milestone: null + node_id: PR_kwDOCwFO9M4vFP9Z + number: 556 + patch_url: https://github.com/packit/hello-world/pull/556.patch + requested_reviewers: [] + requested_teams: [] + review_comment_url: https://api.github.com/repos/packit/hello-world/pulls/comments{/number} + review_comments_url: https://api.github.com/repos/packit/hello-world/pulls/556/comments + state: closed + statuses_url: https://api.github.com/repos/packit/hello-world/statuses/622a20fbd42ca7a70a6d65321b45d556090a13c0 + title: dist-git-branch has been renamed to dist_git_branches + updated_at: '2021-11-30T09:34:09Z' + url: https://api.github.com/repos/packit/hello-world/pulls/556 + user: + avatar_url: https://avatars.githubusercontent.com/u/288686?v=4 + events_url: https://api.github.com/users/jpopelka/events{/privacy} + followers_url: https://api.github.com/users/jpopelka/followers + following_url: https://api.github.com/users/jpopelka/following{/other_user} + gists_url: https://api.github.com/users/jpopelka/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/jpopelka + id: 288686 + login: jpopelka + node_id: MDQ6VXNlcjI4ODY4Ng== + organizations_url: https://api.github.com/users/jpopelka/orgs + received_events_url: https://api.github.com/users/jpopelka/received_events + repos_url: https://api.github.com/users/jpopelka/repos + site_admin: false + starred_url: https://api.github.com/users/jpopelka/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/jpopelka/subscriptions + type: User + url: https://api.github.com/users/jpopelka + user_view_type: public + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; param=groot-preview; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '196' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: pull_requests=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 + https://api.github.com:443/repos/packit/hello-world/commits/f2c98da: + - metadata: + latency: 0.3561985492706299 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.commit + - github.Repository + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + author: null + comments_url: https://api.github.com/repos/packit/hello-world/commits/f2c98da9efc0190628db81cd220fe8cc2a8e9e95/comments + commit: + author: + date: '2023-03-03T10:31:43Z' + email: csomh@redhat.com + name: "Hunor Csomort\xE1ni" + comment_count: 1 + committer: + date: '2023-03-03T10:31:43Z' + email: csomh@redhat.com + name: "Hunor Csomort\xE1ni" + message: "Modernize .packit.yaml\n\nDrop the deprecated config keys.\n\ + \nSigned-off-by: Hunor Csomort\xE1ni " + tree: + sha: a62827b52a7df704b8f80eee8e7d6c08a872685d + url: https://api.github.com/repos/packit/hello-world/git/trees/a62827b52a7df704b8f80eee8e7d6c08a872685d + url: https://api.github.com/repos/packit/hello-world/git/commits/f2c98da9efc0190628db81cd220fe8cc2a8e9e95 + verification: + payload: "tree a62827b52a7df704b8f80eee8e7d6c08a872685d\nparent fc6f281825c946572d0f8c2c6ea3b63809b76647\n\ + author Hunor Csomort\xE1ni 1677839503 +0100\n\ + committer Hunor Csomort\xE1ni 1677839503 +0100\n\ + \nModernize .packit.yaml\n\nDrop the deprecated config keys.\n\n\ + Signed-off-by: Hunor Csomort\xE1ni \n" + reason: no_user + signature: '-----BEGIN PGP SIGNATURE----- + + + iQEzBAABCAAdFiEEvbtio33HhIXR9z4nJOzqhCG/J58FAmQBzKgACgkQJOzqhCG/ + + J58K3gf/ZPwpTXdQZ4wnV8dzWYcQWA8mgk7ML/oGHYy2ffBucMVJc9q42mXnqhjk + + nhFUObyh17pKHJ+q5hwpjP8ivPufAUD4jRgYkVIhjEFFprnSg4kNqkZMtgjHf6qF + + fKHmJEWpqeaBlWQJezdMgv0PDiJUE33qL9tR2IifOHw2qa2tbBQU0P4pAHafS6zf + + 4r1gvl1oEfaRazji6XAPFNd70eM02tkbQzr/ZqGW+tk8EDUaUCeIVUBlGUNL0lvq + + 3gOisCsL8Jmg4/Nl3XZqoEM169bKDZf9X6iqHEUKoMgrM7IIavzshGv4wrC7U6or + + lGfb66ZxbqpaatnIz23O6mfhrX3ljg== + + =d5zd + + -----END PGP SIGNATURE-----' + verified: false + verified_at: null + committer: null + files: + - additions: 15 + blob_url: https://github.com/packit/hello-world/blob/f2c98da9efc0190628db81cd220fe8cc2a8e9e95/.packit.yaml + changes: 34 + contents_url: https://api.github.com/repos/packit/hello-world/contents/.packit.yaml?ref=f2c98da9efc0190628db81cd220fe8cc2a8e9e95 + deletions: 19 + filename: .packit.yaml + patch: "@@ -1,7 +1,8 @@\n ---\n packit_instances: [\"prod\", \"stg\"\ + ]\n specfile_path: hello.spec\n-synced_files:\n+files_to_sync:\n+\ + \ - .packit.yaml\n - hello.spec\n upstream_package_name: hello\n\ + \ downstream_package_name: hello\n@@ -12,34 +13,29 @@ downstream_package_name:\ + \ hello\n jobs:\n - job: copr_build\n trigger: pull_request\n- \ + \ metadata:\n- targets:\n- - fedora-stable-x86_64\n- - fedora-rawhide-x86_64\n\ + + targets:\n+ - fedora-stable-x86_64\n+ - fedora-rawhide-x86_64\n\ + \ \n - job: copr_build\n trigger: release\n- metadata:\n- targets:\n\ + - - fedora-stable\n+ targets:\n+ - fedora-stable\n \n - job:\ + \ copr_build\n trigger: commit\n- metadata:\n- branch: main\n\ + - targets:\n- - fedora-stable\n+ branch: main\n+ targets:\n\ + + - fedora-stable\n \n - job: tests\n trigger: pull_request\n\ + - metadata:\n- targets:\n- - fedora-stable-x86_64\n- - fedora-rawhide-x86_64\n\ + + targets:\n+ - fedora-stable-x86_64\n+ - fedora-rawhide-x86_64\n\ + \ \n - job: propose_downstream\n trigger: release\n packit_instances:\ + \ [\"stg\"]\n- metadata:\n- dist_git_branches:\n- - fedora-all\n\ + + dist_git_branches:\n+ - fedora-all" + raw_url: https://github.com/packit/hello-world/raw/f2c98da9efc0190628db81cd220fe8cc2a8e9e95/.packit.yaml + sha: dce8acc376266b277763db048b1a9fbe4f2be2fb + status: modified + html_url: https://github.com/packit/hello-world/commit/f2c98da9efc0190628db81cd220fe8cc2a8e9e95 + node_id: C_kwDOCwFO9NoAKGYyYzk4ZGE5ZWZjMDE5MDYyOGRiODFjZDIyMGZlOGNjMmE4ZTllOTU + parents: + - html_url: https://github.com/packit/hello-world/commit/fc6f281825c946572d0f8c2c6ea3b63809b76647 + sha: fc6f281825c946572d0f8c2c6ea3b63809b76647 + url: https://api.github.com/repos/packit/hello-world/commits/fc6f281825c946572d0f8c2c6ea3b63809b76647 + sha: f2c98da9efc0190628db81cd220fe8cc2a8e9e95 + stats: + additions: 15 + deletions: 19 + total: 34 + url: https://api.github.com/repos/packit/hello-world/commits/f2c98da9efc0190628db81cd220fe8cc2a8e9e95 + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Fri, 03 Mar 2023 10:31:43 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '197' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: contents=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 + https://api.github.com:443/repos/packit/hello-world/commits/f2c98da9efc0190628db81cd220fe8cc2a8e9e95/pulls: + - metadata: + latency: 0.30278682708740234 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.services.github.commit + - github.PaginatedList + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: [] + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Length: '2' + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; param=groot-preview; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '198' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: pull_requests=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 diff --git a/tests/integration/github/test_data/test_commit/Commit.test_get_relative_commit.yaml b/tests/integration/github/test_data/test_commit/Commit.test_get_relative_commit.yaml new file mode 100644 index 000000000..b68ec7700 --- /dev/null +++ b/tests/integration/github/test_data/test_commit/Commit.test_get_relative_commit.yaml @@ -0,0 +1,602 @@ +_requre: + DataTypes: 1 + key_strategy: StorageKeysInspectSimple + version_storage_file: 3 +requests.sessions: + send: + GET: + https://api.github.com:443/repos/packit/hello-world: + - metadata: + latency: 0.3226652145385742 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.commit + - ogr.services.github.project + - github.MainClass + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + allow_forking: true + archive_url: https://api.github.com/repos/packit/hello-world/{archive_format}{/ref} + archived: false + assignees_url: https://api.github.com/repos/packit/hello-world/assignees{/user} + blobs_url: https://api.github.com/repos/packit/hello-world/git/blobs{/sha} + branches_url: https://api.github.com/repos/packit/hello-world/branches{/branch} + clone_url: https://github.com/packit/hello-world.git + collaborators_url: https://api.github.com/repos/packit/hello-world/collaborators{/collaborator} + comments_url: https://api.github.com/repos/packit/hello-world/comments{/number} + commits_url: https://api.github.com/repos/packit/hello-world/commits{/sha} + compare_url: https://api.github.com/repos/packit/hello-world/compare/{base}...{head} + contents_url: https://api.github.com/repos/packit/hello-world/contents/{+path} + contributors_url: https://api.github.com/repos/packit/hello-world/contributors + created_at: '2019-05-02T18:54:46Z' + custom_properties: {} + default_branch: main + deployments_url: https://api.github.com/repos/packit/hello-world/deployments + description: The most progresive command-line tool in the world. + disabled: false + downloads_url: https://api.github.com/repos/packit/hello-world/downloads + events_url: https://api.github.com/repos/packit/hello-world/events + fork: false + forks: 23 + forks_count: 23 + forks_url: https://api.github.com/repos/packit/hello-world/forks + full_name: packit/hello-world + git_commits_url: https://api.github.com/repos/packit/hello-world/git/commits{/sha} + git_refs_url: https://api.github.com/repos/packit/hello-world/git/refs{/sha} + git_tags_url: https://api.github.com/repos/packit/hello-world/git/tags{/sha} + git_url: git://github.com/packit/hello-world.git + has_discussions: false + has_downloads: true + has_issues: true + has_pages: false + has_projects: true + has_wiki: true + homepage: null + hooks_url: https://api.github.com/repos/packit/hello-world/hooks + html_url: https://github.com/packit/hello-world + id: 184635124 + is_template: false + issue_comment_url: https://api.github.com/repos/packit/hello-world/issues/comments{/number} + issue_events_url: https://api.github.com/repos/packit/hello-world/issues/events{/number} + issues_url: https://api.github.com/repos/packit/hello-world/issues{/number} + keys_url: https://api.github.com/repos/packit/hello-world/keys{/key_id} + labels_url: https://api.github.com/repos/packit/hello-world/labels{/name} + language: Python + languages_url: https://api.github.com/repos/packit/hello-world/languages + license: + key: mit + name: MIT License + node_id: MDc6TGljZW5zZTEz + spdx_id: MIT + url: https://api.github.com/licenses/mit + merges_url: https://api.github.com/repos/packit/hello-world/merges + milestones_url: https://api.github.com/repos/packit/hello-world/milestones{/number} + mirror_url: null + name: hello-world + network_count: 23 + node_id: MDEwOlJlcG9zaXRvcnkxODQ2MzUxMjQ= + notifications_url: https://api.github.com/repos/packit/hello-world/notifications{?since,all,participating} + open_issues: 99 + open_issues_count: 99 + organization: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + owner: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + permissions: + admin: false + maintain: false + pull: true + push: false + triage: false + private: false + pulls_url: https://api.github.com/repos/packit/hello-world/pulls{/number} + pushed_at: '2025-05-23T04:48:00Z' + releases_url: https://api.github.com/repos/packit/hello-world/releases{/id} + size: 224 + ssh_url: git@github.com:packit/hello-world.git + stargazers_count: 4 + stargazers_url: https://api.github.com/repos/packit/hello-world/stargazers + statuses_url: https://api.github.com/repos/packit/hello-world/statuses/{sha} + subscribers_count: 5 + subscribers_url: https://api.github.com/repos/packit/hello-world/subscribers + subscription_url: https://api.github.com/repos/packit/hello-world/subscription + svn_url: https://github.com/packit/hello-world + tags_url: https://api.github.com/repos/packit/hello-world/tags + teams_url: https://api.github.com/repos/packit/hello-world/teams + topics: [] + trees_url: https://api.github.com/repos/packit/hello-world/git/trees{/sha} + updated_at: '2023-01-31T17:16:23Z' + url: https://api.github.com/repos/packit/hello-world + visibility: public + watchers: 4 + watchers_count: 4 + web_commit_signoff_required: false + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Tue, 31 Jan 2023 17:16:23 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '180' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: metadata=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 + https://api.github.com:443/repos/packit/hello-world/commits/test-for-flock%5E%5E: + - metadata: + latency: 0.3338358402252197 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.commit + - github.Repository + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + author: + avatar_url: https://avatars.githubusercontent.com/u/1662493?v=4 + events_url: https://api.github.com/users/TomasTomecek/events{/privacy} + followers_url: https://api.github.com/users/TomasTomecek/followers + following_url: https://api.github.com/users/TomasTomecek/following{/other_user} + gists_url: https://api.github.com/users/TomasTomecek/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/TomasTomecek + id: 1662493 + login: TomasTomecek + node_id: MDQ6VXNlcjE2NjI0OTM= + organizations_url: https://api.github.com/users/TomasTomecek/orgs + received_events_url: https://api.github.com/users/TomasTomecek/received_events + repos_url: https://api.github.com/users/TomasTomecek/repos + site_admin: false + starred_url: https://api.github.com/users/TomasTomecek/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/TomasTomecek/subscriptions + type: User + url: https://api.github.com/users/TomasTomecek + user_view_type: public + comments_url: https://api.github.com/repos/packit/hello-world/commits/7c855533a5d4bd9a7ad51cd22c8789702a38109c/comments + commit: + author: + date: '2019-06-28T11:26:06Z' + email: ttomecek@redhat.com + name: Tomas Tomecek + comment_count: 0 + committer: + date: '2019-06-28T11:26:06Z' + email: noreply@github.com + name: GitHub + message: 'Merge pull request #4 from TomasTomecek/test + + + test' + tree: + sha: d25c47bf57a2eda8bff9326ff21b910b7d28f526 + url: https://api.github.com/repos/packit/hello-world/git/trees/d25c47bf57a2eda8bff9326ff21b910b7d28f526 + url: https://api.github.com/repos/packit/hello-world/git/commits/7c855533a5d4bd9a7ad51cd22c8789702a38109c + verification: + payload: 'tree d25c47bf57a2eda8bff9326ff21b910b7d28f526 + + parent f85554ef3da2dd91b8b2b67ceba5ea07eb43e681 + + parent eadfdd1396393889e9866f412c4a4c1bceb47cc4 + + author Tomas Tomecek 1561721166 +0200 + + committer GitHub 1561721166 +0200 + + + Merge pull request #4 from TomasTomecek/test + + + test' + reason: valid + signature: '-----BEGIN PGP SIGNATURE----- + + + wsBcBAABCAAQBQJdFflOCRBK7hj4Ov3rIwAAdHIIAKFrcauKZr07YcWwBjrRVeSx + + 1aaov+D/vx86RB3+RPH945flyCf9vIkolKML3M+vknwteO0rRBpzX5BWBpVs2q0r + + NANjlTsIBB9mSgXzElglKuwFM1iJSxpbYWyXv3aU55p1D3UtKoEo2L4VTOw3vEfU + + PcToPZOxhusJVDAwL8MG9+C979S16TPzYlp+WCLNWz79tqCk9owvPwZt5WV3Cmmt + + FzDVvIJpoI7xYnoDhJuWWrcQwvT+rJMHfYyv9/V/fjB+I0GqfecCRdAt1Rdzlp3D + + CGK+erzeR0SdjNSKIYfJZArploGJ2oUVhPmqZd5Newo4BzerfcSc87kK9YZLAn4= + + =p7h7 + + -----END PGP SIGNATURE----- + + ' + verified: true + verified_at: '2024-01-16T19:59:59Z' + committer: + avatar_url: https://avatars.githubusercontent.com/u/19864447?v=4 + events_url: https://api.github.com/users/web-flow/events{/privacy} + followers_url: https://api.github.com/users/web-flow/followers + following_url: https://api.github.com/users/web-flow/following{/other_user} + gists_url: https://api.github.com/users/web-flow/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/web-flow + id: 19864447 + login: web-flow + node_id: MDQ6VXNlcjE5ODY0NDQ3 + organizations_url: https://api.github.com/users/web-flow/orgs + received_events_url: https://api.github.com/users/web-flow/received_events + repos_url: https://api.github.com/users/web-flow/repos + site_admin: false + starred_url: https://api.github.com/users/web-flow/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/web-flow/subscriptions + type: User + url: https://api.github.com/users/web-flow + user_view_type: public + files: + - additions: 1 + blob_url: https://github.com/packit/hello-world/blob/7c855533a5d4bd9a7ad51cd22c8789702a38109c/README.md + changes: 2 + contents_url: https://api.github.com/repos/packit/hello-world/contents/README.md?ref=7c855533a5d4bd9a7ad51cd22c8789702a38109c + deletions: 1 + filename: README.md + patch: "@@ -14,5 +14,5 @@ Just open a pull request on this repository\ + \ and packit service will build your c\n \n Follow the steps provided\ + \ by the packit service and then install this tool like this:\n ```bash\n\ + -$ yum install hello\n+$ dnf install hello\n ```" + raw_url: https://github.com/packit/hello-world/raw/7c855533a5d4bd9a7ad51cd22c8789702a38109c/README.md + sha: 0b43e71cc4eaf88d9bd9b45e008681a342085fe1 + status: modified + - additions: 1 + blob_url: https://github.com/packit/hello-world/blob/7c855533a5d4bd9a7ad51cd22c8789702a38109c/hello.spec + changes: 3 + contents_url: https://api.github.com/repos/packit/hello-world/contents/hello.spec?ref=7c855533a5d4bd9a7ad51cd22c8789702a38109c + deletions: 2 + filename: hello.spec + patch: "@@ -1,8 +1,7 @@\n Name: hello\n Version: 0.1.0\n\ + \ Release: 1%{?dist}\n-Summary: Nice and a polite tool\n\ + -\n+Summary: Nice and a polite tool to make your day\n License:\ + \ MIT\n URL: https://github.com/packit-service/hello-world\n\ + \ Source0: hello-%{version}.tar.gz" + raw_url: https://github.com/packit/hello-world/raw/7c855533a5d4bd9a7ad51cd22c8789702a38109c/hello.spec + sha: a1ead0a0447d18a85639fd30d61f3f68a5d6af98 + status: modified + html_url: https://github.com/packit/hello-world/commit/7c855533a5d4bd9a7ad51cd22c8789702a38109c + node_id: MDY6Q29tbWl0MTg0NjM1MTI0OjdjODU1NTMzYTVkNGJkOWE3YWQ1MWNkMjJjODc4OTcwMmEzODEwOWM= + parents: + - html_url: https://github.com/packit/hello-world/commit/f85554ef3da2dd91b8b2b67ceba5ea07eb43e681 + sha: f85554ef3da2dd91b8b2b67ceba5ea07eb43e681 + url: https://api.github.com/repos/packit/hello-world/commits/f85554ef3da2dd91b8b2b67ceba5ea07eb43e681 + - html_url: https://github.com/packit/hello-world/commit/eadfdd1396393889e9866f412c4a4c1bceb47cc4 + sha: eadfdd1396393889e9866f412c4a4c1bceb47cc4 + url: https://api.github.com/repos/packit/hello-world/commits/eadfdd1396393889e9866f412c4a4c1bceb47cc4 + sha: 7c855533a5d4bd9a7ad51cd22c8789702a38109c + stats: + additions: 2 + deletions: 3 + total: 5 + url: https://api.github.com/repos/packit/hello-world/commits/7c855533a5d4bd9a7ad51cd22c8789702a38109c + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Fri, 28 Jun 2019 11:26:06 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '181' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: contents=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 + https://api.github.com:443/repos/packit/hello-world/commits/test-for-flock%5E%5E2: + - metadata: + latency: 0.7459726333618164 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_commit + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.commit + - github.Repository + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + author: + avatar_url: https://avatars.githubusercontent.com/u/633969?v=4 + events_url: https://api.github.com/users/thrix/events{/privacy} + followers_url: https://api.github.com/users/thrix/followers + following_url: https://api.github.com/users/thrix/following{/other_user} + gists_url: https://api.github.com/users/thrix/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/thrix + id: 633969 + login: thrix + node_id: MDQ6VXNlcjYzMzk2OQ== + organizations_url: https://api.github.com/users/thrix/orgs + received_events_url: https://api.github.com/users/thrix/received_events + repos_url: https://api.github.com/users/thrix/repos + site_admin: false + starred_url: https://api.github.com/users/thrix/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/thrix/subscriptions + type: User + url: https://api.github.com/users/thrix + user_view_type: public + comments_url: https://api.github.com/repos/packit/hello-world/commits/aa4883c128cd9bbf64f83cde4cd73e6318611d8b/comments + commit: + author: + date: '2019-08-05T15:41:22Z' + email: mvadkert@redhat.com + name: Miroslav Vadkerti + comment_count: 0 + committer: + date: '2019-08-08T21:55:25Z' + email: mvadkert@redhat.com + name: Miroslav Vadkerti + message: 'Add example for running fmf based selinux tests + + + Signed-off-by: Miroslav Vadkerti ' + tree: + sha: 243e34c0df9eb8c61045d17f0a06abc4202ca8b4 + url: https://api.github.com/repos/packit/hello-world/git/trees/243e34c0df9eb8c61045d17f0a06abc4202ca8b4 + url: https://api.github.com/repos/packit/hello-world/git/commits/aa4883c128cd9bbf64f83cde4cd73e6318611d8b + verification: + payload: null + reason: unsigned + signature: null + verified: false + verified_at: null + committer: + avatar_url: https://avatars.githubusercontent.com/u/633969?v=4 + events_url: https://api.github.com/users/thrix/events{/privacy} + followers_url: https://api.github.com/users/thrix/followers + following_url: https://api.github.com/users/thrix/following{/other_user} + gists_url: https://api.github.com/users/thrix/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/thrix + id: 633969 + login: thrix + node_id: MDQ6VXNlcjYzMzk2OQ== + organizations_url: https://api.github.com/users/thrix/orgs + received_events_url: https://api.github.com/users/thrix/received_events + repos_url: https://api.github.com/users/thrix/repos + site_admin: false + starred_url: https://api.github.com/users/thrix/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/thrix/subscriptions + type: User + url: https://api.github.com/users/thrix + user_view_type: public + files: + - additions: 1 + blob_url: https://github.com/packit/hello-world/blob/aa4883c128cd9bbf64f83cde4cd73e6318611d8b/.fmf%2Fversion + changes: 1 + contents_url: https://api.github.com/repos/packit/hello-world/contents/.fmf%2Fversion?ref=aa4883c128cd9bbf64f83cde4cd73e6318611d8b + deletions: 0 + filename: .fmf/version + patch: '@@ -0,0 +1 @@ + + +1' + raw_url: https://github.com/packit/hello-world/raw/aa4883c128cd9bbf64f83cde4cd73e6318611d8b/.fmf%2Fversion + sha: d00491fd7e5bb6fa28c517a0bb32b8b506539d4d + status: added + - additions: 11 + blob_url: https://github.com/packit/hello-world/blob/aa4883c128cd9bbf64f83cde4cd73e6318611d8b/.packit.yaml + changes: 12 + contents_url: https://api.github.com/repos/packit/hello-world/contents/.packit.yaml?ref=aa4883c128cd9bbf64f83cde4cd73e6318611d8b + deletions: 1 + filename: .packit.yaml + patch: "@@ -12,4 +12,14 @@ jobs:\n trigger: pull_request\n metadata:\n\ + \ targets:\n- - rhelbeta-8-x86_64\n+ - fedora-29-x86_64\n\ + + - fedora-30-x86_64\n+ - fedora-rawhide-x86_64\n+\n+- job:\ + \ tests\n+ trigger: pull_request\n+ metadata:\n+ targets:\n+\ + \ - fedora-29-x86_64\n+ - fedora-30-x86_64\n+ - fedora-rawhide-x86_64" + raw_url: https://github.com/packit/hello-world/raw/aa4883c128cd9bbf64f83cde4cd73e6318611d8b/.packit.yaml + sha: d76a9f8b362df93faae05561156b57444824c20e + status: modified + - additions: 9 + blob_url: https://github.com/packit/hello-world/blob/aa4883c128cd9bbf64f83cde4cd73e6318611d8b/ci.fmf + changes: 9 + contents_url: https://api.github.com/repos/packit/hello-world/contents/ci.fmf?ref=aa4883c128cd9bbf64f83cde4cd73e6318611d8b + deletions: 0 + filename: ci.fmf + patch: '@@ -0,0 +1,9 @@ + + +--- + + +/test/build/smoke: + + + execute: + + + how: shell + + + commands: + + + - dnf -y install httpd curl + + + - systemctl start httpd + + + - echo foo > /var/www/html/index.html + + + - curl http://localhost/ | grep foo' + raw_url: https://github.com/packit/hello-world/raw/aa4883c128cd9bbf64f83cde4cd73e6318611d8b/ci.fmf + sha: 385516bb261643a5f85aa9e27e325133a295e07d + status: added + html_url: https://github.com/packit/hello-world/commit/aa4883c128cd9bbf64f83cde4cd73e6318611d8b + node_id: MDY6Q29tbWl0MTg0NjM1MTI0OmFhNDg4M2MxMjhjZDliYmY2NGY4M2NkZTRjZDczZTYzMTg2MTFkOGI= + parents: + - html_url: https://github.com/packit/hello-world/commit/7c855533a5d4bd9a7ad51cd22c8789702a38109c + sha: 7c855533a5d4bd9a7ad51cd22c8789702a38109c + url: https://api.github.com/repos/packit/hello-world/commits/7c855533a5d4bd9a7ad51cd22c8789702a38109c + sha: aa4883c128cd9bbf64f83cde4cd73e6318611d8b + stats: + additions: 21 + deletions: 1 + total: 22 + url: https://api.github.com/repos/packit/hello-world/commits/aa4883c128cd9bbf64f83cde4cd73e6318611d8b + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Thu, 08 Aug 2019 21:55:25 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '182' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: contents=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 diff --git a/tests/integration/github/test_data/test_pull_requests/PullRequests.test_changes.yaml b/tests/integration/github/test_data/test_pull_requests/PullRequests.test_changes.yaml new file mode 100644 index 000000000..2c22c7796 --- /dev/null +++ b/tests/integration/github/test_data/test_pull_requests/PullRequests.test_changes.yaml @@ -0,0 +1,804 @@ +_requre: + DataTypes: 1 + key_strategy: StorageKeysInspectSimple + version_storage_file: 3 +requests.sessions: + send: + GET: + https://api.github.com:443/repos/packit/hello-world: + - metadata: + latency: 0.33986639976501465 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_pull_requests + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.pull_request + - ogr.services.github.project + - github.MainClass + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + allow_forking: true + archive_url: https://api.github.com/repos/packit/hello-world/{archive_format}{/ref} + archived: false + assignees_url: https://api.github.com/repos/packit/hello-world/assignees{/user} + blobs_url: https://api.github.com/repos/packit/hello-world/git/blobs{/sha} + branches_url: https://api.github.com/repos/packit/hello-world/branches{/branch} + clone_url: https://github.com/packit/hello-world.git + collaborators_url: https://api.github.com/repos/packit/hello-world/collaborators{/collaborator} + comments_url: https://api.github.com/repos/packit/hello-world/comments{/number} + commits_url: https://api.github.com/repos/packit/hello-world/commits{/sha} + compare_url: https://api.github.com/repos/packit/hello-world/compare/{base}...{head} + contents_url: https://api.github.com/repos/packit/hello-world/contents/{+path} + contributors_url: https://api.github.com/repos/packit/hello-world/contributors + created_at: '2019-05-02T18:54:46Z' + custom_properties: {} + default_branch: main + deployments_url: https://api.github.com/repos/packit/hello-world/deployments + description: The most progresive command-line tool in the world. + disabled: false + downloads_url: https://api.github.com/repos/packit/hello-world/downloads + events_url: https://api.github.com/repos/packit/hello-world/events + fork: false + forks: 23 + forks_count: 23 + forks_url: https://api.github.com/repos/packit/hello-world/forks + full_name: packit/hello-world + git_commits_url: https://api.github.com/repos/packit/hello-world/git/commits{/sha} + git_refs_url: https://api.github.com/repos/packit/hello-world/git/refs{/sha} + git_tags_url: https://api.github.com/repos/packit/hello-world/git/tags{/sha} + git_url: git://github.com/packit/hello-world.git + has_discussions: false + has_downloads: true + has_issues: true + has_pages: false + has_projects: true + has_wiki: true + homepage: null + hooks_url: https://api.github.com/repos/packit/hello-world/hooks + html_url: https://github.com/packit/hello-world + id: 184635124 + is_template: false + issue_comment_url: https://api.github.com/repos/packit/hello-world/issues/comments{/number} + issue_events_url: https://api.github.com/repos/packit/hello-world/issues/events{/number} + issues_url: https://api.github.com/repos/packit/hello-world/issues{/number} + keys_url: https://api.github.com/repos/packit/hello-world/keys{/key_id} + labels_url: https://api.github.com/repos/packit/hello-world/labels{/name} + language: Python + languages_url: https://api.github.com/repos/packit/hello-world/languages + license: + key: mit + name: MIT License + node_id: MDc6TGljZW5zZTEz + spdx_id: MIT + url: https://api.github.com/licenses/mit + merges_url: https://api.github.com/repos/packit/hello-world/merges + milestones_url: https://api.github.com/repos/packit/hello-world/milestones{/number} + mirror_url: null + name: hello-world + network_count: 23 + node_id: MDEwOlJlcG9zaXRvcnkxODQ2MzUxMjQ= + notifications_url: https://api.github.com/repos/packit/hello-world/notifications{?since,all,participating} + open_issues: 99 + open_issues_count: 99 + organization: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + owner: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + permissions: + admin: false + maintain: false + pull: true + push: false + triage: false + private: false + pulls_url: https://api.github.com/repos/packit/hello-world/pulls{/number} + pushed_at: '2025-05-23T04:48:00Z' + releases_url: https://api.github.com/repos/packit/hello-world/releases{/id} + size: 224 + ssh_url: git@github.com:packit/hello-world.git + stargazers_count: 4 + stargazers_url: https://api.github.com/repos/packit/hello-world/stargazers + statuses_url: https://api.github.com/repos/packit/hello-world/statuses/{sha} + subscribers_count: 5 + subscribers_url: https://api.github.com/repos/packit/hello-world/subscribers + subscription_url: https://api.github.com/repos/packit/hello-world/subscription + svn_url: https://github.com/packit/hello-world + tags_url: https://api.github.com/repos/packit/hello-world/tags + teams_url: https://api.github.com/repos/packit/hello-world/teams + topics: [] + trees_url: https://api.github.com/repos/packit/hello-world/git/trees{/sha} + updated_at: '2023-01-31T17:16:23Z' + url: https://api.github.com/repos/packit/hello-world + visibility: public + watchers: 4 + watchers_count: 4 + web_commit_signoff_required: false + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Tue, 31 Jan 2023 17:16:23 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '101' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: metadata=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 + https://api.github.com:443/repos/packit/hello-world/pulls/2: + - metadata: + latency: 0.44113874435424805 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_pull_requests + - ogr.abstract + - ogr.utils + - ogr.abstract + - ogr.services.github.pull_request + - github.Repository + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + _links: + comments: + href: https://api.github.com/repos/packit/hello-world/issues/2/comments + commits: + href: https://api.github.com/repos/packit/hello-world/pulls/2/commits + html: + href: https://github.com/packit/hello-world/pull/2 + issue: + href: https://api.github.com/repos/packit/hello-world/issues/2 + review_comment: + href: https://api.github.com/repos/packit/hello-world/pulls/comments{/number} + review_comments: + href: https://api.github.com/repos/packit/hello-world/pulls/2/comments + self: + href: https://api.github.com/repos/packit/hello-world/pulls/2 + statuses: + href: https://api.github.com/repos/packit/hello-world/statuses/d3a39758121397cc76e01d79fa30a4a1b3961a0f + active_lock_reason: null + additions: 7 + assignee: null + assignees: [] + author_association: MEMBER + auto_merge: null + base: + label: packit:master + ref: master + repo: + allow_forking: true + archive_url: https://api.github.com/repos/packit/hello-world/{archive_format}{/ref} + archived: false + assignees_url: https://api.github.com/repos/packit/hello-world/assignees{/user} + blobs_url: https://api.github.com/repos/packit/hello-world/git/blobs{/sha} + branches_url: https://api.github.com/repos/packit/hello-world/branches{/branch} + clone_url: https://github.com/packit/hello-world.git + collaborators_url: https://api.github.com/repos/packit/hello-world/collaborators{/collaborator} + comments_url: https://api.github.com/repos/packit/hello-world/comments{/number} + commits_url: https://api.github.com/repos/packit/hello-world/commits{/sha} + compare_url: https://api.github.com/repos/packit/hello-world/compare/{base}...{head} + contents_url: https://api.github.com/repos/packit/hello-world/contents/{+path} + contributors_url: https://api.github.com/repos/packit/hello-world/contributors + created_at: '2019-05-02T18:54:46Z' + default_branch: main + deployments_url: https://api.github.com/repos/packit/hello-world/deployments + description: The most progresive command-line tool in the world. + disabled: false + downloads_url: https://api.github.com/repos/packit/hello-world/downloads + events_url: https://api.github.com/repos/packit/hello-world/events + fork: false + forks: 23 + forks_count: 23 + forks_url: https://api.github.com/repos/packit/hello-world/forks + full_name: packit/hello-world + git_commits_url: https://api.github.com/repos/packit/hello-world/git/commits{/sha} + git_refs_url: https://api.github.com/repos/packit/hello-world/git/refs{/sha} + git_tags_url: https://api.github.com/repos/packit/hello-world/git/tags{/sha} + git_url: git://github.com/packit/hello-world.git + has_discussions: false + has_downloads: true + has_issues: true + has_pages: false + has_projects: true + has_wiki: true + homepage: null + hooks_url: https://api.github.com/repos/packit/hello-world/hooks + html_url: https://github.com/packit/hello-world + id: 184635124 + is_template: false + issue_comment_url: https://api.github.com/repos/packit/hello-world/issues/comments{/number} + issue_events_url: https://api.github.com/repos/packit/hello-world/issues/events{/number} + issues_url: https://api.github.com/repos/packit/hello-world/issues{/number} + keys_url: https://api.github.com/repos/packit/hello-world/keys{/key_id} + labels_url: https://api.github.com/repos/packit/hello-world/labels{/name} + language: Python + languages_url: https://api.github.com/repos/packit/hello-world/languages + license: + key: mit + name: MIT License + node_id: MDc6TGljZW5zZTEz + spdx_id: MIT + url: https://api.github.com/licenses/mit + merges_url: https://api.github.com/repos/packit/hello-world/merges + milestones_url: https://api.github.com/repos/packit/hello-world/milestones{/number} + mirror_url: null + name: hello-world + node_id: MDEwOlJlcG9zaXRvcnkxODQ2MzUxMjQ= + notifications_url: https://api.github.com/repos/packit/hello-world/notifications{?since,all,participating} + open_issues: 99 + open_issues_count: 99 + owner: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + private: false + pulls_url: https://api.github.com/repos/packit/hello-world/pulls{/number} + pushed_at: '2025-05-23T04:48:00Z' + releases_url: https://api.github.com/repos/packit/hello-world/releases{/id} + size: 224 + ssh_url: git@github.com:packit/hello-world.git + stargazers_count: 4 + stargazers_url: https://api.github.com/repos/packit/hello-world/stargazers + statuses_url: https://api.github.com/repos/packit/hello-world/statuses/{sha} + subscribers_url: https://api.github.com/repos/packit/hello-world/subscribers + subscription_url: https://api.github.com/repos/packit/hello-world/subscription + svn_url: https://github.com/packit/hello-world + tags_url: https://api.github.com/repos/packit/hello-world/tags + teams_url: https://api.github.com/repos/packit/hello-world/teams + topics: [] + trees_url: https://api.github.com/repos/packit/hello-world/git/trees{/sha} + updated_at: '2023-01-31T17:16:23Z' + url: https://api.github.com/repos/packit/hello-world + visibility: public + watchers: 4 + watchers_count: 4 + web_commit_signoff_required: false + sha: 3103e78667c1b336eef36117cef3577ee78b86bc + user: + avatar_url: https://avatars.githubusercontent.com/u/46870917?v=4 + events_url: https://api.github.com/users/packit/events{/privacy} + followers_url: https://api.github.com/users/packit/followers + following_url: https://api.github.com/users/packit/following{/other_user} + gists_url: https://api.github.com/users/packit/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/packit + id: 46870917 + login: packit + node_id: MDEyOk9yZ2FuaXphdGlvbjQ2ODcwOTE3 + organizations_url: https://api.github.com/users/packit/orgs + received_events_url: https://api.github.com/users/packit/received_events + repos_url: https://api.github.com/users/packit/repos + site_admin: false + starred_url: https://api.github.com/users/packit/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/packit/subscriptions + type: Organization + url: https://api.github.com/users/packit + user_view_type: public + body: 'We stored payload of Github webhook for creation of this PR internally + to verify production packit service: hence this PR will get a ton of + feedback in the future.' + changed_files: 3 + closed_at: '2019-05-03T09:17:55Z' + comments: 13 + comments_url: https://api.github.com/repos/packit/hello-world/issues/2/comments + commits: 3 + commits_url: https://api.github.com/repos/packit/hello-world/pulls/2/commits + created_at: '2019-05-03T06:11:38Z' + deletions: 5 + diff_url: https://github.com/packit/hello-world/pull/2.diff + draft: false + head: + label: TomasTomecek:test + ref: test + repo: + allow_forking: true + archive_url: https://api.github.com/repos/TomasTomecek/hello-world/{archive_format}{/ref} + archived: false + assignees_url: https://api.github.com/repos/TomasTomecek/hello-world/assignees{/user} + blobs_url: https://api.github.com/repos/TomasTomecek/hello-world/git/blobs{/sha} + branches_url: https://api.github.com/repos/TomasTomecek/hello-world/branches{/branch} + clone_url: https://github.com/TomasTomecek/hello-world.git + collaborators_url: https://api.github.com/repos/TomasTomecek/hello-world/collaborators{/collaborator} + comments_url: https://api.github.com/repos/TomasTomecek/hello-world/comments{/number} + commits_url: https://api.github.com/repos/TomasTomecek/hello-world/commits{/sha} + compare_url: https://api.github.com/repos/TomasTomecek/hello-world/compare/{base}...{head} + contents_url: https://api.github.com/repos/TomasTomecek/hello-world/contents/{+path} + contributors_url: https://api.github.com/repos/TomasTomecek/hello-world/contributors + created_at: '2019-05-02T18:55:43Z' + default_branch: master + deployments_url: https://api.github.com/repos/TomasTomecek/hello-world/deployments + description: The most progresive command-line tool in the world. + disabled: false + downloads_url: https://api.github.com/repos/TomasTomecek/hello-world/downloads + events_url: https://api.github.com/repos/TomasTomecek/hello-world/events + fork: true + forks: 0 + forks_count: 0 + forks_url: https://api.github.com/repos/TomasTomecek/hello-world/forks + full_name: TomasTomecek/hello-world + git_commits_url: https://api.github.com/repos/TomasTomecek/hello-world/git/commits{/sha} + git_refs_url: https://api.github.com/repos/TomasTomecek/hello-world/git/refs{/sha} + git_tags_url: https://api.github.com/repos/TomasTomecek/hello-world/git/tags{/sha} + git_url: git://github.com/TomasTomecek/hello-world.git + has_discussions: false + has_downloads: true + has_issues: false + has_pages: false + has_projects: true + has_wiki: true + homepage: null + hooks_url: https://api.github.com/repos/TomasTomecek/hello-world/hooks + html_url: https://github.com/TomasTomecek/hello-world + id: 184635270 + is_template: false + issue_comment_url: https://api.github.com/repos/TomasTomecek/hello-world/issues/comments{/number} + issue_events_url: https://api.github.com/repos/TomasTomecek/hello-world/issues/events{/number} + issues_url: https://api.github.com/repos/TomasTomecek/hello-world/issues{/number} + keys_url: https://api.github.com/repos/TomasTomecek/hello-world/keys{/key_id} + labels_url: https://api.github.com/repos/TomasTomecek/hello-world/labels{/name} + language: null + languages_url: https://api.github.com/repos/TomasTomecek/hello-world/languages + license: + key: mit + name: MIT License + node_id: MDc6TGljZW5zZTEz + spdx_id: MIT + url: https://api.github.com/licenses/mit + merges_url: https://api.github.com/repos/TomasTomecek/hello-world/merges + milestones_url: https://api.github.com/repos/TomasTomecek/hello-world/milestones{/number} + mirror_url: null + name: hello-world + node_id: MDEwOlJlcG9zaXRvcnkxODQ2MzUyNzA= + notifications_url: https://api.github.com/repos/TomasTomecek/hello-world/notifications{?since,all,participating} + open_issues: 1 + open_issues_count: 1 + owner: + avatar_url: https://avatars.githubusercontent.com/u/1662493?v=4 + events_url: https://api.github.com/users/TomasTomecek/events{/privacy} + followers_url: https://api.github.com/users/TomasTomecek/followers + following_url: https://api.github.com/users/TomasTomecek/following{/other_user} + gists_url: https://api.github.com/users/TomasTomecek/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/TomasTomecek + id: 1662493 + login: TomasTomecek + node_id: MDQ6VXNlcjE2NjI0OTM= + organizations_url: https://api.github.com/users/TomasTomecek/orgs + received_events_url: https://api.github.com/users/TomasTomecek/received_events + repos_url: https://api.github.com/users/TomasTomecek/repos + site_admin: false + starred_url: https://api.github.com/users/TomasTomecek/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/TomasTomecek/subscriptions + type: User + url: https://api.github.com/users/TomasTomecek + user_view_type: public + private: false + pulls_url: https://api.github.com/repos/TomasTomecek/hello-world/pulls{/number} + pushed_at: '2023-05-11T10:59:10Z' + releases_url: https://api.github.com/repos/TomasTomecek/hello-world/releases{/id} + size: 42 + ssh_url: git@github.com:TomasTomecek/hello-world.git + stargazers_count: 0 + stargazers_url: https://api.github.com/repos/TomasTomecek/hello-world/stargazers + statuses_url: https://api.github.com/repos/TomasTomecek/hello-world/statuses/{sha} + subscribers_url: https://api.github.com/repos/TomasTomecek/hello-world/subscribers + subscription_url: https://api.github.com/repos/TomasTomecek/hello-world/subscription + svn_url: https://github.com/TomasTomecek/hello-world + tags_url: https://api.github.com/repos/TomasTomecek/hello-world/tags + teams_url: https://api.github.com/repos/TomasTomecek/hello-world/teams + topics: [] + trees_url: https://api.github.com/repos/TomasTomecek/hello-world/git/trees{/sha} + updated_at: '2019-05-02T18:55:46Z' + url: https://api.github.com/repos/TomasTomecek/hello-world + visibility: public + watchers: 0 + watchers_count: 0 + web_commit_signoff_required: false + sha: d3a39758121397cc76e01d79fa30a4a1b3961a0f + user: + avatar_url: https://avatars.githubusercontent.com/u/1662493?v=4 + events_url: https://api.github.com/users/TomasTomecek/events{/privacy} + followers_url: https://api.github.com/users/TomasTomecek/followers + following_url: https://api.github.com/users/TomasTomecek/following{/other_user} + gists_url: https://api.github.com/users/TomasTomecek/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/TomasTomecek + id: 1662493 + login: TomasTomecek + node_id: MDQ6VXNlcjE2NjI0OTM= + organizations_url: https://api.github.com/users/TomasTomecek/orgs + received_events_url: https://api.github.com/users/TomasTomecek/received_events + repos_url: https://api.github.com/users/TomasTomecek/repos + site_admin: false + starred_url: https://api.github.com/users/TomasTomecek/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/TomasTomecek/subscriptions + type: User + url: https://api.github.com/users/TomasTomecek + user_view_type: public + html_url: https://github.com/packit/hello-world/pull/2 + id: 275601158 + issue_url: https://api.github.com/repos/packit/hello-world/issues/2 + labels: [] + locked: false + maintainer_can_modify: false + merge_commit_sha: 9e2507855e635373d124a5b5411d8955bae23a66 + mergeable: false + mergeable_state: dirty + merged: true + merged_at: '2019-05-03T09:17:55Z' + merged_by: + avatar_url: https://avatars.githubusercontent.com/u/1662493?v=4 + events_url: https://api.github.com/users/TomasTomecek/events{/privacy} + followers_url: https://api.github.com/users/TomasTomecek/followers + following_url: https://api.github.com/users/TomasTomecek/following{/other_user} + gists_url: https://api.github.com/users/TomasTomecek/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/TomasTomecek + id: 1662493 + login: TomasTomecek + node_id: MDQ6VXNlcjE2NjI0OTM= + organizations_url: https://api.github.com/users/TomasTomecek/orgs + received_events_url: https://api.github.com/users/TomasTomecek/received_events + repos_url: https://api.github.com/users/TomasTomecek/repos + site_admin: false + starred_url: https://api.github.com/users/TomasTomecek/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/TomasTomecek/subscriptions + type: User + url: https://api.github.com/users/TomasTomecek + user_view_type: public + milestone: null + node_id: MDExOlB1bGxSZXF1ZXN0Mjc1NjAxMTU4 + number: 2 + patch_url: https://github.com/packit/hello-world/pull/2.patch + rebaseable: false + requested_reviewers: [] + requested_teams: [] + review_comment_url: https://api.github.com/repos/packit/hello-world/pulls/comments{/number} + review_comments: 0 + review_comments_url: https://api.github.com/repos/packit/hello-world/pulls/2/comments + state: closed + statuses_url: https://api.github.com/repos/packit/hello-world/statuses/d3a39758121397cc76e01d79fa30a4a1b3961a0f + title: improve readme + updated_at: '2020-08-20T12:13:37Z' + url: https://api.github.com/repos/packit/hello-world/pulls/2 + user: + avatar_url: https://avatars.githubusercontent.com/u/1662493?v=4 + events_url: https://api.github.com/users/TomasTomecek/events{/privacy} + followers_url: https://api.github.com/users/TomasTomecek/followers + following_url: https://api.github.com/users/TomasTomecek/following{/other_user} + gists_url: https://api.github.com/users/TomasTomecek/gists{/gist_id} + gravatar_id: '' + html_url: https://github.com/TomasTomecek + id: 1662493 + login: TomasTomecek + node_id: MDQ6VXNlcjE2NjI0OTM= + organizations_url: https://api.github.com/users/TomasTomecek/orgs + received_events_url: https://api.github.com/users/TomasTomecek/received_events + repos_url: https://api.github.com/users/TomasTomecek/repos + site_admin: false + starred_url: https://api.github.com/users/TomasTomecek/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/TomasTomecek/subscriptions + type: User + url: https://api.github.com/users/TomasTomecek + user_view_type: public + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Sat, 10 May 2025 13:11:34 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '102' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: pull_requests=read; contents=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 + https://api.github.com:443/repos/packit/hello-world/pulls/2/files: + - metadata: + latency: 0.31330370903015137 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_pull_requests + - ogr.services.github.changes + - github.PaginatedList + - github.Requester + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 2 + _content: + - additions: 4 + blob_url: https://github.com/packit/hello-world/blob/d3a39758121397cc76e01d79fa30a4a1b3961a0f/.packit.yaml + changes: 8 + contents_url: https://api.github.com/repos/packit/hello-world/contents/.packit.yaml?ref=d3a39758121397cc76e01d79fa30a4a1b3961a0f + deletions: 4 + filename: .packit.yaml + patch: "@@ -3,10 +3,10 @@ specfile_path: hello.spec\n synced_files:\n\ + \ - hello.spec\n downstream_package_name: hello\n-acrions:\n- post-upstream-clone:\ + \ \"python3 setup.py sdist --dist-dir .\"\n-current_version_command:\ + \ [\"python3\", \"setup.py\", \"--version\"]\n-create_tarball_command:\ + \ [\"python3\", \"setup.py\", \"sdist\", \"--dist-dir\", \".\"]\n+#\ + \ actions:\n+# post-upstream-clone: \"python3 setup.py sdist --dist-dir\ + \ .\"\n+# current_version_command: [\"python3\", \"setup.py\", \"--version\"\ + ]\n+# create_tarball_command: [\"python3\", \"setup.py\", \"sdist\"\ + , \"--dist-dir\", \".\"]\n jobs:\n - job: copr_build\n trigger: pull_request" + raw_url: https://github.com/packit/hello-world/raw/d3a39758121397cc76e01d79fa30a4a1b3961a0f/.packit.yaml + sha: b7a91d8cda2e0e53e1eb93cdf74f44a736f43d12 + status: modified + - additions: 2 + blob_url: https://github.com/packit/hello-world/blob/d3a39758121397cc76e01d79fa30a4a1b3961a0f/README.md + changes: 2 + contents_url: https://api.github.com/repos/packit/hello-world/contents/README.md?ref=d3a39758121397cc76e01d79fa30a4a1b3961a0f + deletions: 0 + filename: README.md + patch: "@@ -1,5 +1,7 @@\n # hello-world\n \n+The simplest python CLI tool\ + \ used to demonstrate packit service functionality. It will make your\ + \ day.\n+\n ```\n $ hello world!\n Hello world!" + raw_url: https://github.com/packit/hello-world/raw/d3a39758121397cc76e01d79fa30a4a1b3961a0f/README.md + sha: a24ab72f1fb6dac09ca4dc1d6c70f5fb5c0a0300 + status: modified + - additions: 1 + blob_url: https://github.com/packit/hello-world/blob/d3a39758121397cc76e01d79fa30a4a1b3961a0f/hello.spec + changes: 2 + contents_url: https://api.github.com/repos/packit/hello-world/contents/hello.spec?ref=d3a39758121397cc76e01d79fa30a4a1b3961a0f + deletions: 1 + filename: hello.spec + patch: "@@ -5,7 +5,7 @@ Summary: Nice and a polite tool\n \n License:\ + \ MIT\n URL: https://github.com/packit-service/hello-world\n\ + -Source0: hello-0.1.0.tar.gz\n+Source0: hello-%{version}.tar.gz\n\ + \ BuildArch: noarch\n BuildRequires: python3-devel\n " + raw_url: https://github.com/packit/hello-world/raw/d3a39758121397cc76e01d79fa30a4a1b3961a0f/hello.spec + sha: fb8f70743e95a8f9d116bced4a7e298559000d4c + status: modified + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Access-Control-Allow-Origin: '*' + Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, + X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, + X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, + X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, + Sunset + Cache-Control: private, max-age=60, s-maxage=60 + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: application/json; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Last-Modified: Sat, 10 May 2025 13:11:34 GMT + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: Accept, Authorization, Cookie, X-GitHub-OTP,Accept-Encoding, Accept, + X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Media-Type: github.v3; format=json + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-RateLimit-Limit: '5000' + X-RateLimit-Remaining: '4972' + X-RateLimit-Reset: '1572953901' + X-RateLimit-Resource: core + X-RateLimit-Used: '103' + X-XSS-Protection: '0' + github-authentication-token-expiration: 2025-06-22 10:14:27 +0200 + x-accepted-github-permissions: pull_requests=read + x-github-api-version-selected: '2022-11-28' + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 + https://github.com/packit/hello-world/pull/2.patch: + - metadata: + latency: 0.5894331932067871 + module_call_list: + - unittest.case + - requre.record_and_replace + - tests.integration.github.test_pull_requests + - ogr.services.github.changes + - requests.api + - requests.sessions + - requre.objects + - requre.cassette + - requests.sessions + - send + output: + __store_indicator: 1 + _content: "From 230baab63826456591846afce509e6ceb61d519e Mon Sep 17 00:00:00\ + \ 2001\nFrom: Tomas Tomecek \nDate: Fri, 3 May 2019\ + \ 08:11:14 +0200\nSubject: [PATCH 1/3] improve readme even more\n\nSigned-off-by:\ + \ Tomas Tomecek \n---\n README.md | 2 ++\n 1 file\ + \ changed, 2 insertions(+)\n\ndiff --git a/README.md b/README.md\nindex\ + \ 394cc101..a24ab72f 100644\n--- a/README.md\n+++ b/README.md\n@@ -1,5\ + \ +1,7 @@\n # hello-world\n \n+The simplest python CLI tool used to demonstrate\ + \ packit service functionality. It will make your day.\n+\n ```\n $ hello\ + \ world!\n Hello world!\n\nFrom 48507582377a9f0475a30f2ec4e3ab663bb3fb1d\ + \ Mon Sep 17 00:00:00 2001\nFrom: Tomas Tomecek \n\ + Date: Fri, 3 May 2019 09:03:20 +0200\nSubject: [PATCH 2/3] spec: use %version\ + \ in %source\n\nSigned-off-by: Tomas Tomecek \n---\n\ + \ hello.spec | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\n\ + diff --git a/hello.spec b/hello.spec\nindex cc474d4f..fb8f7074 100644\n\ + --- a/hello.spec\n+++ b/hello.spec\n@@ -5,7 +5,7 @@ Summary: Nice\ + \ and a polite tool\n \n License: MIT\n URL: https://github.com/packit-service/hello-world\n\ + -Source0: hello-0.1.0.tar.gz\n+Source0: hello-%{version}.tar.gz\n\ + \ BuildArch: noarch\n BuildRequires: python3-devel\n \n\nFrom d3a39758121397cc76e01d79fa30a4a1b3961a0f\ + \ Mon Sep 17 00:00:00 2001\nFrom: Tomas Tomecek \n\ + Date: Fri, 3 May 2019 09:07:03 +0200\nSubject: [PATCH 3/3] use default\ + \ packit implementation for srpm\n\nSigned-off-by: Tomas Tomecek \n\ + ---\n .packit.yaml | 8 ++++----\n 1 file changed, 4 insertions(+), 4 deletions(-)\n\ + \ndiff --git a/.packit.yaml b/.packit.yaml\nindex 21bc3e32..b7a91d8c 100644\n\ + --- a/.packit.yaml\n+++ b/.packit.yaml\n@@ -3,10 +3,10 @@ specfile_path:\ + \ hello.spec\n synced_files:\n - hello.spec\n downstream_package_name:\ + \ hello\n-acrions:\n- post-upstream-clone: \"python3 setup.py sdist --dist-dir\ + \ .\"\n-current_version_command: [\"python3\", \"setup.py\", \"--version\"\ + ]\n-create_tarball_command: [\"python3\", \"setup.py\", \"sdist\", \"\ + --dist-dir\", \".\"]\n+# actions:\n+# post-upstream-clone: \"python3\ + \ setup.py sdist --dist-dir .\"\n+# current_version_command: [\"python3\"\ + , \"setup.py\", \"--version\"]\n+# create_tarball_command: [\"python3\"\ + , \"setup.py\", \"sdist\", \"--dist-dir\", \".\"]\n jobs:\n - job: copr_build\n\ + \ trigger: pull_request\n" + _next: null + elapsed: 0.2 + encoding: utf-8 + headers: + Cache-Control: max-age=0, private, must-revalidate + Content-Encoding: gzip + Content-Security-Policy: default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' + https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; + object-src 'none';base-uri 'self';img-src 'self' https:; + Content-Type: text/plain; charset=utf-8 + Date: Fri, 01 Nov 2019 13-36-03 GMT + ETag: W/"1e51b8e1c48787a433405211e9e0fe61" + Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin + Server: github.com + Set-Cookie: a='b'; + Strict-Transport-Security: max-age=31536000; includeSubdomains; preload + Transfer-Encoding: chunked + Vary: X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame,Accept-Encoding, + Accept, X-Requested-With + X-Content-Type-Options: nosniff + X-Frame-Options: deny + X-GitHub-Request-Id: 18FB:AA1A:99616C4:B8092CB:5CC15425 + X-XSS-Protection: '0' + x-repository-download: git clone https://github.com/packit/hello-world.git + raw: !!binary "" + raw_decoded: !!binary "" + reason: OK + status_code: 200 diff --git a/tests/integration/github/test_pull_requests.py b/tests/integration/github/test_pull_requests.py index e6848293d..e23088cc4 100644 --- a/tests/integration/github/test_pull_requests.py +++ b/tests/integration/github/test_pull_requests.py @@ -361,6 +361,11 @@ def test_pr_patch(self): assert isinstance(patch, bytes) assert "\nDate: Mon, 18 Nov 2019 12:42:35 +0100\n" in patch.decode() + def test_changes(self): + pr = self.hello_world_project.get_pr(2) + changes = pr.changes + assert list(changes.files) == [".packit.yaml", "README.md", "hello.spec"] + def test_get_comment(self): comment = self.hello_world_project.get_pr(72).get_comment(559765628) assert comment.body == "check comment updates\r\n\r\nedit"