Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unit tests using Pytest for github_projects.py. #58

Merged
merged 2 commits into from
Oct 30, 2024

Conversation

MobiTikula
Copy link
Collaborator

@MobiTikula MobiTikula commented Oct 23, 2024

Implement unit tests using Pytest for action inputs file.

  • Unit tests
  • For observation of code coverage by unit tests use pytest-cov.
  • Goal is 80+% score.

Release Notes:

  • Unit tests using Pytest for github_projects.py file.

@MobiTikula MobiTikula added the enhancement New feature or request label Oct 23, 2024
@MobiTikula MobiTikula self-assigned this Oct 23, 2024
miroslavpojer
miroslavpojer previously approved these changes Oct 24, 2024
Copy link
Collaborator

@miroslavpojer miroslavpojer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • pulled
  • code review
  • local run performed
  • unit test ran

@@ -185,7 +184,7 @@ def get_project_issues(self, project: GithubProject) -> list[ProjectIssue]:

# Extend project issues list per every page during pagination
project_issues_raw.extend(project_issue_data)
logger.debug("Received `%s` issue records from project: %s.", len(project_issue_data), project.title)
logger.debug("Received `%i` issue/s records from project: %s.", len(project_issue_data), project.title)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
logger.debug("Received `%i` issue/s records from project: %s.", len(project_issue_data), project.title)
logger.debug("Received `%i` issue(s) records from project: %s.", len(project_issue_data), project.title)

@@ -197,6 +196,6 @@ def get_project_issues(self, project: GithubProject) -> list[ProjectIssue]:
for issue in (ProjectIssue().loads(issue_json, project) for issue_json in project_issues_raw)
if issue is not None
]
logger.debug("Loaded `%s` issues from project: %s.", len(project_issues), project.title)
logger.debug("Loaded `%i` issue/s from project: %s.", len(project_issues), project.title)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
logger.debug("Loaded `%i` issue/s from project: %s.", len(project_issues), project.title)
logger.debug("Loaded `%i` issue(s) from project: %s.", len(project_issues), project.title)

@MobiTikula MobiTikula merged commit f7f8814 into master Oct 30, 2024
3 of 4 checks passed
@MobiTikula MobiTikula deleted the feature/34-Introduce-Unit-Tests-Github-Projects branch October 30, 2024 08:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants