@@ -28,14 +28,14 @@ def skipper(test):
2828 return skipper
2929
3030
31- def missing_format (checker ):
31+ def missing_format (Validator ):
3232 def missing_format (test ): # pragma: no cover
3333 schema = test .schema
3434 if (
3535 schema is True
3636 or schema is False
3737 or "format" not in schema
38- or schema ["format" ] in checker .checkers
38+ or schema ["format" ] in Validator . FORMAT_CHECKER .checkers
3939 or test .valid
4040 ):
4141 return
@@ -150,10 +150,10 @@ def leap_second(test):
150150 DRAFT3 .optional_tests_of (name = "non-bmp-regex" ),
151151 DRAFT3 .optional_tests_of (name = "zeroTerminatedFloats" ),
152152 Validator = jsonschema .Draft3Validator ,
153- format_checker = jsonschema .draft3_format_checker ,
153+ format_checker = jsonschema .Draft3Validator . FORMAT_CHECKER ,
154154 skip = lambda test : (
155155 narrow_unicode_build (test )
156- or missing_format (jsonschema .draft3_format_checker )(test )
156+ or missing_format (jsonschema .Draft3Validator )(test )
157157 or complex_email_validation (test )
158158 or skip (
159159 message = bug (),
@@ -175,12 +175,12 @@ def leap_second(test):
175175 DRAFT4 .optional_tests_of (name = "non-bmp-regex" ),
176176 DRAFT4 .optional_tests_of (name = "zeroTerminatedFloats" ),
177177 Validator = jsonschema .Draft4Validator ,
178- format_checker = jsonschema .draft4_format_checker ,
178+ format_checker = jsonschema .Draft4Validator . FORMAT_CHECKER ,
179179 skip = lambda test : (
180180 narrow_unicode_build (test )
181181 or allowed_leading_zeros (test )
182182 or leap_second (test )
183- or missing_format (jsonschema .draft4_format_checker )(test )
183+ or missing_format (jsonschema .Draft4Validator )(test )
184184 or complex_email_validation (test )
185185 or skip (
186186 message = bug (),
@@ -236,12 +236,12 @@ def leap_second(test):
236236 DRAFT6 .optional_tests_of (name = "float-overflow" ),
237237 DRAFT6 .optional_tests_of (name = "non-bmp-regex" ),
238238 Validator = jsonschema .Draft6Validator ,
239- format_checker = jsonschema .draft6_format_checker ,
239+ format_checker = jsonschema .Draft6Validator . FORMAT_CHECKER ,
240240 skip = lambda test : (
241241 narrow_unicode_build (test )
242242 or allowed_leading_zeros (test )
243243 or leap_second (test )
244- or missing_format (jsonschema .draft6_format_checker )(test )
244+ or missing_format (jsonschema .Draft6Validator )(test )
245245 or complex_email_validation (test )
246246 or skip (
247247 message = bug (),
@@ -260,12 +260,12 @@ def leap_second(test):
260260 DRAFT7 .optional_tests_of (name = "float-overflow" ),
261261 DRAFT7 .optional_tests_of (name = "non-bmp-regex" ),
262262 Validator = jsonschema .Draft7Validator ,
263- format_checker = jsonschema .draft7_format_checker ,
263+ format_checker = jsonschema .Draft7Validator . FORMAT_CHECKER ,
264264 skip = lambda test : (
265265 narrow_unicode_build (test )
266266 or allowed_leading_zeros (test )
267267 or leap_second (test )
268- or missing_format (jsonschema .draft7_format_checker )(test )
268+ or missing_format (jsonschema .Draft7Validator )(test )
269269 or complex_email_validation (test )
270270 or skip (
271271 message = bug (),
@@ -408,12 +408,12 @@ def leap_second(test):
408408TestDraft201909Format = DRAFT201909 .to_unittest_testcase (
409409 DRAFT201909 .format_tests (),
410410 Validator = jsonschema .Draft201909Validator ,
411- format_checker = jsonschema .draft201909_format_checker ,
411+ format_checker = jsonschema .Draft201909Validator . FORMAT_CHECKER ,
412412 skip = lambda test : (
413413 complex_email_validation (test )
414414 or allowed_leading_zeros (test )
415415 or leap_second (test )
416- or missing_format (jsonschema .draft201909_format_checker )(test )
416+ or missing_format (jsonschema .Draft201909Validator )(test )
417417 or complex_email_validation (test )
418418 ),
419419)
@@ -533,12 +533,12 @@ def leap_second(test):
533533TestDraft202012Format = DRAFT202012 .to_unittest_testcase (
534534 DRAFT202012 .format_tests (),
535535 Validator = jsonschema .Draft202012Validator ,
536- format_checker = jsonschema .draft202012_format_checker ,
536+ format_checker = jsonschema .Draft202012Validator . FORMAT_CHECKER ,
537537 skip = lambda test : (
538538 complex_email_validation (test )
539539 or allowed_leading_zeros (test )
540540 or leap_second (test )
541- or missing_format (jsonschema .draft202012_format_checker )(test )
541+ or missing_format (jsonschema .Draft202012Validator )(test )
542542 or complex_email_validation (test )
543543 ),
544544)
0 commit comments