File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -266,9 +266,11 @@ class JsonSchemaTest : StringSpec({
266266 }
267267})
268268
269- private val schemaV7 = SchemaRegistry .withDefaultDialect(SpecificationVersion .DRAFT_7 ) { builder ->
270- builder.schemaLoader { schemaLoader ->
271- schemaLoader.fetchRemoteResources()
269+ private val schemaRegistry: SchemaRegistry by lazy {
270+ SchemaRegistry .withDefaultDialect(SpecificationVersion .DRAFT_7 ) { builder ->
271+ builder.schemaLoader { schemaLoader ->
272+ schemaLoader.fetchRemoteResources()
273+ }
272274 }
273275}
274276
@@ -281,4 +283,4 @@ private val repositoryConfigurationAnalyzerConfiguration =
281283private val repositoryConfigurationPackageManagerConfiguration =
282284 File (" ../integrations/schemas/repository-configurations/package-manager-configuration-schema.json" ).toURI()
283285
284- private fun getSchema (uri : URI ) = schemaV7 .getSchema(uri.toURL().openStream())
286+ private fun getSchema (uri : URI ) = schemaRegistry .getSchema(uri.toURL().openStream())
You can’t perform that action at this time.
0 commit comments