Skip to content

Commit

Permalink
Move the hyper-schema.
Browse files Browse the repository at this point in the history
  • Loading branch information
johnbillion committed Jul 13, 2024
1 parent 8b3750c commit 51e8008
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 235 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,3 @@

/composer.lock
/package-lock.json
/tests/hyper-schema/index.js
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@
"scripts": {
"version": "cd packages/wp-types && npm version $(node -p -e \"require('../../package.json').version\") && git add .",
"build-wp-types": "json2ts -i schema.json -o packages/wp-types/index.ts --style.trailingComma=all --style.useTabs && cat packages/wp-types/append.ts >> packages/wp-types/index.ts",
"build-hyper-schema-types": "json2ts -i tests/hyper-schema/hyper-schema.json -o tests/hyper-schema/index.ts --style.trailingComma=all --style.useTabs",
"test-wp-types": "tsc packages/wp-types/tests/test.ts --noEmit --strict",
"validate": "ajv compile --strict --strict-schema=false -c ajv-formats -m tests/hyper-schema/hyper-schema.json -s schema.json -r \"schemas/**/*.json\""
"validate": "ajv compile --strict --strict-schema=false -c ajv-formats -m tests/external-schemas/hyper-schema.json -s schema.json -r \"schemas/**/*.json\""
}
}
2 changes: 1 addition & 1 deletion tests/bin/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ function validate_schema() {
local filename=${base/.json/}

ls tests/data/$filename/*.json > /dev/null
./node_modules/.bin/ajv validate --strict --strict-schema=false -c ajv-formats -m tests/hyper-schema/hyper-schema.json -r schema.json -r $rflag -s "$file" -d "tests/data/$filename/*.json"
./node_modules/.bin/ajv validate --strict --strict-schema=false -c ajv-formats -m tests/external-schemas/hyper-schema.json -r schema.json -r $rflag -s "$file" -d "tests/data/$filename/*.json"
}

IGNORE_FILES=("schemas/rest-api/error.json" "schemas/rest-api/category.json" "schemas/rest-api/tag.json" "schemas/rest-api/page.json")
Expand Down
File renamed without changes.
231 changes: 0 additions & 231 deletions tests/hyper-schema/index.ts

This file was deleted.

0 comments on commit 51e8008

Please sign in to comment.