Skip to content

✨ Add graphql support and add first graphql endpoint#21

Merged
IamPekka058 merged 7 commits intomainfrom
feature/addGraphQLService
Aug 17, 2025
Merged

✨ Add graphql support and add first graphql endpoint#21
IamPekka058 merged 7 commits intomainfrom
feature/addGraphQLService

Conversation

@IamPekka058
Copy link
Copy Markdown
Member

This pull request introduces GraphQL support to the GitHub client library and adds the ability to delete issues using the GitHub GraphQL API. The main changes include adding a new GraphQLService, updating the GitHub client to expose GraphQL functionality, extending the IssuesService with a deleteIssue method, and adding unit tests for issue deletion.

GraphQL Integration:

  • Added a new GraphQLService class (lib/src/common/graphql_service.dart) to handle GraphQL queries and mutations, using the graphql package.
  • Updated the GitHub client (lib/src/common/github.dart) to include a graphql getter, providing access to the new GraphQL service. [1] [2] [3]
  • Added the graphql package as a dependency in pubspec.yaml.

Issue Deletion Feature:

  • Implemented a new deleteIssue method in IssuesService (lib/src/services/issues_service.dart) that deletes issues via the GraphQL API, since this functionality is not available in the REST API.

Testing Enhancements:

  • Added manual mocks for GitHub and GraphQLService in the unit tests, and introduced tests for the new deleteIssue method, covering both success and failure scenarios (test/unit/issues_test.dart). [1] [2] [3]

@IamPekka058 IamPekka058 requested a review from Ruby11235 August 17, 2025 10:06
@IamPekka058 IamPekka058 added the enhancement New feature or request label Aug 17, 2025
@IamPekka058 IamPekka058 linked an issue Aug 17, 2025 that may be closed by this pull request
@Ruby11235 Ruby11235 requested a review from Friedinger August 17, 2025 12:46
@IamPekka058 IamPekka058 merged commit 991c882 into main Aug 17, 2025
1 check passed
@IamPekka058 IamPekka058 deleted the feature/addGraphQLService branch August 17, 2025 12:52
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.

✨ Add ability to delete issues

3 participants