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

Add validators for built-in formats #6

Open
16 tasks
jacksmith15 opened this issue Nov 20, 2019 · 0 comments
Open
16 tasks

Add validators for built-in formats #6

jacksmith15 opened this issue Nov 20, 2019 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@jacksmith15
Copy link
Owner

jacksmith15 commented Nov 20, 2019

JSONSchema specifies several preset values for the "format" keyword for validating strings, along with the validation logic they should perform. "uuid" and "date-time" are already implemented, the following are not:

  • "time"
  • "date"
  • "email"
  • "idn-email"
  • "hostname"
  • "idn-hostname"
  • "ipv4"
  • "ipv6"
  • "uri"
  • "uri-reference"
  • "iri"
  • "iri-reference"
  • "uri-template"
  • "json-pointer"
  • "relative-json-pointer"
  • "regex"

The correct validation logic for each is specified here.

Currently only validation for "date-time" and "uuid" is enabled (see here).

The remaining format validators should be implemented here.

An example test for "uuid" can be found here.

@jacksmith15 jacksmith15 added enhancement New feature or request good first issue Good for newcomers labels Nov 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant