File tree Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -14,9 +14,11 @@ import warnings
14
14
try :
15
15
import jsonschema .validators
16
16
except ImportError :
17
- jsonschema = None
17
+ jsonschema = Unresolvable = None
18
18
VALIDATORS = {}
19
19
else :
20
+ from referencing .exceptions import Unresolvable
21
+
20
22
VALIDATORS = {
21
23
"draft3" : jsonschema .validators .Draft3Validator ,
22
24
"draft4" : jsonschema .validators .Draft4Validator ,
@@ -587,7 +589,7 @@ class SanityTests(unittest.TestCase):
587
589
with self .subTest (case = case , version = version .name ):
588
590
try :
589
591
Validator (case ["schema" ]).is_valid (12 )
590
- except jsonschema . exceptions . RefResolutionError :
592
+ except Unresolvable :
591
593
pass
592
594
593
595
@unittest .skipIf (jsonschema is None , "Validation library not present!" )
@@ -615,9 +617,6 @@ class SanityTests(unittest.TestCase):
615
617
with self .subTest (path = path ):
616
618
try :
617
619
validator .validate (cases )
618
- except jsonschema .exceptions .RefResolutionError :
619
- # python-jsonschema/jsonschema#884
620
- pass
621
620
except jsonschema .ValidationError as error :
622
621
self .fail (str (error ))
623
622
Original file line number Diff line number Diff line change @@ -5,5 +5,5 @@ skipsdist = True
5
5
6
6
[testenv:sanity]
7
7
# used just for validating the structure of the test case files themselves
8
- deps = jsonschema ==4.18.0a4
8
+ deps = jsonschema ==4.19.0
9
9
commands = {envpython} bin/jsonschema_suite check
You can’t perform that action at this time.
0 commit comments