summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Berman <Julian@GrayVines.com>2021-08-18 08:06:46 +0100
committerJulian Berman <Julian@GrayVines.com>2021-08-18 08:06:46 +0100
commit00828320e6f107ceabf886eac809cd4b2a187c1e (patch)
tree8525befa078b49e69f6ac4077b9f371ff642263c
parent9fd13403ba3d361b4ad04467756c3f38d983118a (diff)
downloadjsonschema-00828320e6f107ceabf886eac809cd4b2a187c1e.tar.gz
Don't check schemas in test suite runs.
Saves a bit of work (given test suite schemas are 'guaranteed' to be valid), but more importantly is easier to debug with a debugger since there's only one pass of validation for an example.
-rw-r--r--jsonschema/tests/_suite.py9
1 files changed, 2 insertions, 7 deletions
diff --git a/jsonschema/tests/_suite.py b/jsonschema/tests/_suite.py
index 1735a74..931dd69 100644
--- a/jsonschema/tests/_suite.py
+++ b/jsonschema/tests/_suite.py
@@ -208,13 +208,8 @@ class _Test(object):
store=self._remotes,
id_of=Validator.ID_OF,
)
- jsonschema.validate(
- instance=self.data,
- schema=self.schema,
- cls=Validator,
- resolver=resolver,
- **kwargs,
- )
+ validator = Validator(schema=self.schema, resolver=resolver, **kwargs)
+ validator.validate(instance=self.data)
def validate_ignoring_errors(self, Validator): # pragma: no cover
try: