Skip to content

Commit

Permalink
work around npx not being available in a GitHub Action
Browse files Browse the repository at this point in the history
  • Loading branch information
dslmeinte committed Nov 10, 2023
1 parent 72155a0 commit a34c2db
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,8 @@
# isnt' parsed by the GitHub Action:
/deno.lock

# NPM (for AJV):
/node_modules
/package-lock.json
/package.json

9 changes: 8 additions & 1 deletion test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,14 @@

deno task run-tests

# install AJV:
npm init -y
npm install ajv
npm install ajv-cli
npm install ajv-formats

# validate schema using AJV:
TS_LIONCORE_M3_SCHEMA=../repos/lionweb-typescript/packages/artifacts/schemas/lioncore_m3.serialization.schema.json
JAVA_LIONCORE_SERIALIZATION=../repos/lionweb-java/core/src/test/resources/serialization/lioncore.json
npx ajv -c ajv-formats --spec=draft2020 --strict=true --allErrors=true --allowUnionTypes=true test -s $TS_LIONCORE_M3_SCHEMA -d $JAVA_LIONCORE_SERIALIZATION --valid
./node_modules/.bin/ajv -c ajv-formats --spec=draft2020 --strict=true --allErrors=true --allowUnionTypes=true test -s $TS_LIONCORE_M3_SCHEMA -d $JAVA_LIONCORE_SERIALIZATION --valid

0 comments on commit a34c2db

Please sign in to comment.