-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add GHA job to test against all iso-10303 schemas
- Loading branch information
Showing
2 changed files
with
51 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: "validate_schemas" | ||
|
||
on: | ||
push: | ||
branches: [ main ] | ||
pull_request: | ||
workflow_dispatch: | ||
|
||
concurrency: | ||
group: '${{ github.workflow }}-${{ github.job }}-${{ github.head_ref || github.ref_name }}' | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
schemas: | ||
name: Validate schemas | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
test-group: | ||
[ | ||
'iso-10303/schemas-srl.yml', | ||
'iso-10303/schemas_module.yml', | ||
'iso-10303/schemas_bom.yml', | ||
] | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
repository: 'metanorma/iso-10303' | ||
path: iso-10303 | ||
token: ${{ secrets.LUTAML_CI_PAT_TOKEN }} | ||
|
||
- name: Install Ruby | ||
uses: ruby/setup-ruby@master | ||
with: | ||
ruby-version: 3.2 | ||
bundler-cache: true | ||
cache-version: 0 # Increment this number if you need to re-download cached gems | ||
|
||
- name: Validate schemas ${{ matrix.test-group }} | ||
run: | | ||
ls -l | ||
yq '.schemas[].path | sub("../../iso-10303/", "")' ${{ matrix.test-group }} | xargs bundle exec ./exe/expressir validate | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters