#NEWLINE# def test_schema_validation_error( tmpdir ) : #NEWLINE# #INDENT# tmpfile = os . path . join ( str ( tmpdir ) , 'basic' ) #NEWLINE# handler = state . StateHandler ( test_path ) #NEWLINE# item = { #NEWLINE# #INDENT# 'tmpfile' : tmpfile , #NEWLINE# 'num' : 'five' , #NEWLINE# #UNINDENT# } #NEWLINE# with pytest . raises ( jsonschema . ValidationError ) as ex : #NEWLINE# #INDENT# handler . apply ( 'test1' , [ item ] , True ) #NEWLINE# #UNINDENT# assert ( tmpdir . value . cause is None ) #NEWLINE# assert ( ex . value . validator_value == 'integer' )