

def test_recognize_batch_sends_data_with_unique_id_to_worker(self):
    self.id_generator.set_id([1])
    self.worker.recognize_batch(self.request_data, self.request_headers)
    expected_message = createRecognitionRequestMessage('BATCH', b'some wav', False, id=1, frame_rate=16000, new_lm='default')
    self.assertThatMessagesWereSentToWorker([expected_message])

dataset/ETHPy150Open UFAL-DSG/cloud-asr/cloudasr/api/test_lib.py TestFrontendWorker.test_recognize_batch_sends_data_with_unique_id_to_worker/original