Add Commands for Remaining Scrapyd API Endpoints #133
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Related: #98
This pull request adds new functionalities to the
ScrapydClient
class and introduces comprehensive test coverage for these features. The changes include new methods for managing Scrapyd projects, versions, and jobs, as well as corresponding unit tests to ensure their correctness.New Features in
ScrapydClient
:Daemon Status and Versions Management:
daemonstatus
method to fetch the status of the Scrapyd daemon.versions
method to list versions of a given project.Project and Version Deletion:
delproject
method to delete a project, with error handling for non-existent projects.delversion
method to delete specific or all versions of a project, with error handling for invalid versions.Job Management:
cancel
method to cancel a specific job or all running jobs within a project, with validation for project and job existence.Test Coverage:
Tests for Daemon Status and Versions:
daemonstatus
to validate successful and error responses.versions
to handle scenarios with valid versions, no versions, and error responses.Tests for Project and Version Deletion:
delproject
to ensure proper handling of non-existent projects and successful deletion.delversion
to validate deletion of specific or all versions and error handling for invalid inputs.Tests for Job Management:
cancel
to verify cancellation of specific jobs, all jobs, and error handling for invalid projects or jobs.