Skip to content

Migrate isApiInfoJsonSchema to use built-in schema function #77

@andreyyudin

Description

@andreyyudin

Description:
Refactor src/functions/isApiInfoJsonSchema.js to use Spectral’s built-in schema function instead of a custom validation implementation. This will align the rule with the current best practices for schema-based validation in Spectral and reduce maintenance overhead.

Benefits:

  • Leverages Spectral’s native schema handling and validation capabilities.
  • Simplifies codebase by removing custom JSON schema logic.
  • Ensures consistent validation behavior across all rules.

Acceptance Criteria:

  • isApiInfoJsonSchema.js no longer exists.
  • The rule calls Spectral’s built-in schema function for evaluation.
  • Unit tests confirm equivalent or improved behavior compared to the old implementation.

Proposed Steps:

  1. Replace custom validation logic with Spectral schema function usage.
  2. Update rule configuration and references accordingly.
  3. Verify rule output consistency with tests.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions