def test_make_grammar_info(self, mock_get_queue, mock_put): with self.app.test_request_context(): make_grammar_info('blank') assert mock_get_queue.called mock_put.assert_called_with(self.make_request( 'make_grammar_info', ('blank', 'guest') ))
def _determine_values_to_return(self): self._get_grams() if self._need_redirect(): self._display_redirect() elif self._grammars_selected(): worker_jobs.make_grammar_info(self.dset_name) self._display_global_stats() else: self._display_no_grammars_exist()