#NEWLINE# def in_scope( self , region , scope ) : #NEWLINE# #INDENT# scope_region = self . scopes ( ) . find_first ( scope , region ) #NEWLINE# if scope_region . empty ( ) : #NEWLINE# #INDENT# return CheckFailed ( 'should be in scope "{}" but no such scope found' . format ( scope ) ) #NEWLINE# #UNINDENT# if ( not scope_region . contains ( region ) ) : #NEWLINE# #INDENT# return CheckFailed ( 'should be in scope "{}" but that scope covers only "{}"' . format ( scope , self . text ( scope_region ) ) ) #NEWLINE# #UNINDENT# return CheckPassed ( )