#NEWLINE# @ patch ( 'lintreview.web.get_repository' ) #NEWLINE# @ patch ( 'lintreview.web.get_lintrc' ) #NEWLINE# @ patch ( 'lintreview.web.process_pull_request' ) #NEWLINE# def test_start_review_schedule_job( self , task , lintrc , get_repo ) : #NEWLINE# #INDENT# get_repo . return_value = Mock ( ) #NEWLINE# opened = test_data . copy ( ) #NEWLINE# opened [ 'action' ] = 'opened' #NEWLINE# data = json . dumps ( opened ) #NEWLINE# lintrc . return_value = '\n[tools]\nlinters = pep8' #NEWLINE# res = self . app . post ( '/review/start' , content_type = 'application/json' , data = data ) #NEWLINE# assert task . delay . called , 'Process request should be called' #NEWLINE# eq_ ( 204 , res . status_code ) #NEWLINE# eq_ ( '' , opened . data )