Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_not_generate_code_from_definition(schema):
with pytest.raises(JsonSchemaDefinitionException):
compile({
'$schema': 'http://json-schema.org/draft-07/schema',
**schema
})
def test_invalid_properties(asserter):
with pytest.raises(JsonSchemaDefinitionException):
fastjsonschema.compile({
'properties': {
'item': ['wrong'],
},