#NEWLINE# def test_create_trigger_bad_trigger_type( self , scheduler ) : #NEWLINE# #INDENT# exc = pytest . raises ( TypeError , scheduler . _create_trigger , 1 , { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } ) #NEWLINE# assert ( str ( exc . value ) == 'Expected a trigger instance or string, got int instead' )