Skip to content

Commit f3c4d2e

Browse files
authored
Merge pull request #2111 from effigies/fix/schema-import
fix: Import schema correctly from JSR
2 parents b005d9d + 2c7239f commit f3c4d2e

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

.github/workflows/deno_tests.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,12 @@ jobs:
3939
strategy:
4040
matrix:
4141
os: [ubuntu-22.04, macos-12, windows-2022]
42+
allow-net: [true, false]
4243
fail-fast: false
4344
defaults:
4445
run:
4546
working-directory: ./bids-validator
47+
shell: bash
4648

4749
steps:
4850
- uses: actions/checkout@v4
@@ -51,7 +53,13 @@ jobs:
5153
- uses: denoland/setup-deno@v1
5254
with:
5355
deno-version: v1.x
54-
- run: deno test --allow-all --coverage=cov/ src/
56+
- name: Set permissions with network access
57+
run: echo 'PERMS=--allow-read --allow-write --allow-env --allow-run --allow-net' >> $GITHUB_ENV
58+
if: ${{ matrix.allow-net }}
59+
- name: Set permissions without network access
60+
run: echo 'PERMS=--allow-read --allow-write --allow-env --allow-run --deny-net' >> $GITHUB_ENV
61+
if: ${{ ! matrix.allow-net }}
62+
- run: deno test $PERMS --coverage=cov/ src/
5563
- name: Collect coverage
5664
run: deno coverage cov/ --lcov --output=coverage.lcov
5765
if: ${{ always() }}

bids-validator/src/setup/loadSchema.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import type { Schema } from '../types/schema.ts'
22
import { objectPathHandler } from '../utils/objectPathHandler.ts'
3-
import * as schemaDefault from '@bids/schema/schema' with { type: 'json' }
3+
import { default as schemaDefault } from '@bids/schema/schema' with { type: 'json' }
44
import { setCustomMetadataFormats } from '../validators/json.ts'
55

66
/**

0 commit comments

Comments
 (0)