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

API-30 FetchingData.FetchingResources #55

Conversation

ezenity
Copy link
Contributor

@ezenity ezenity commented Dec 20, 2023

Added New Spectral Rules for JSON:API v1.0 FetchingData.FetchingResources

This introduces a new set of Spectral rules specifically tailored for validation JSON:API v1.0 Fetching Data - Fetching Resources within an OpenAPI Document. Key Highlights Include:

  • Creation of Spectral rules to ensure compliance with JSON:API v1.0 standards, focusing on Fetching Data for Fetching Resources specifications.
  • Ensuring fetched resources is supporting the proper format for every URL as 'self' link and/or 'related' link is the proper location within responses.

These additions significantly improve our capability to automatically validate and ensure the consistency of API responses with the JSON:API v1.0 standard.

This commit introduces a new set of Spectral rules specifically tailored for validating JSON:API v1.0 Fetching Data - Fetching Resources within an OpenAPI Document. Key highlights include:

- Creation of Spectral rules to ensure compliance with JSON:API v1.0 standards, focusing on Fetching Resources specifications.
- Validating that a server MUST supprt fetching resource data for every URL that is provided to a strict format.

These additions significantly improve our capability to automatically validate and ensure the consistency of API responses with the JSON:API v1.0 standard.
This document serves as a standardized template for verifying positive test scenarios in ruleset development. To ensure that the document can be tested against multiple rulesets, the design and endpoints were refactored. This document is now closer to adhering to JSON:API v1.0 specifications. Covered sections include:
- ContentNegotiation.ClientResponsibilities
- ContentNegotiation.ServerResponsibilities
- DocumentStructure
- DocumentStructure.TopLevel
- DocumentStructure.ResourceObjects
- DocumentStructure.ResourceObjects.Attributes
- DocumentStructure.Links
- DocumentStructure.MetaInformation
- DocumentStructure.MemberNames
- FetchingData.FetchingResources
- FetchingData.Sorting
- FetchingData.Pagination
- FetchingData.Filtering
- Errors.ProcessingErrors
- Errors.ErrorObjects
This commit marks the completion of detailed test cases for all of the JSON:API v1.0 Fetching Data - Fetching Resources ruleset.

These updates significantly improve the robustness and relaibility of the JSON:API v1.0 specifications for Fetching Resources validation process.
- These two files provides a way to test all the created rules for both positive and negative scenarios.
- Created a failing-rules.yaml which generates a way to trigger all the rules to display the error message
- Updated the passing-rules.yaml to adhere to the specifications of JSON:API v1.0 for Fetching Resources.
@ezenity ezenity marked this pull request as ready for review December 21, 2023 05:34
@AkshayPathakMLF AkshayPathakMLF merged commit e8e750b into jmlue42:main Dec 27, 2023
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants