-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Add author filter option for [GithubCommitActivity] (#9251)
* feat: Add author filter option for CommitActivity Add a new filter option to [GithubCommitActivity], allowing users to filter the commit activity by a specific author. To make the filter more explicit, The label display "commits by [author]" for the total amount of commits and "commit activity by [author]" for other intervals when an author filter is selected. To maintain a clear and organized code structure, The filtered author is added as an argument and not to the shield path. The request to find the number of commits by the author is made using the REST api rather then the GraphQL api to make it in 1 request rather then 2. Resolves #9215 * fix: solve eslint errors * Add tests for [GithubCommitActivity] filter by author Add tests for the new filter by author feature. * update [GithubCommitActivity] spec file for new author feat Add test for new transformAuthorFilter function of GithubCommitActivity added for the author filter feature. * Fix null string for label of GithubCommitActivity * Update GithubCommitActivity example * improve error handeling for GithubCommitActivity The author filter error handling removed was redundent as it would never execute, there is no way to seperate branch not found from repo not found. * update depricated functions PR #9233 replaced errorsMessages with httpErrors. This commit updates the new changes to stay up to date with that PR * remove test for nonexisting error this exception was removed in commit 9e358c8 and is not needed anymore * Fixed test for commit activity unexisting repo * Update example for GithubCommitActivity Picked a user with commits in the repo as an example that would work * Add test for invalid commit activity branch Add test for REST API calls in commit activity branch --------- Co-authored-by: jNullj <[email protected]>
- Loading branch information
Showing
2 changed files
with
126 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters