packages/lang/python/python-jsonschema-specifications/test.sh
Jeffery To ebb69c5c17 python-jsonschema-specifications: Add new package
From the README:

JSON support files from the JSON Schema Specifications (metaschemas,
vocabularies, etc.), packaged for runtime access from Python as a
referencing-based Schema Registry.

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2023-11-30 12:57:27 +08:00

12 lines
293 B
Bash

#!/bin/sh
[ "$1" = python3-jsonschema-specifications ] || exit 0
python3 - << 'EOF'
from jsonschema_specifications import REGISTRY as SPECIFICATIONS
DRAFT202012_DIALECT_URI = "https://json-schema.org/draft/2020-12/schema"
assert SPECIFICATIONS.contents(DRAFT202012_DIALECT_URI) != ""
EOF