| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include <vector> | 5 #include <vector> |
| 6 | 6 |
| 7 #include "content/browser/browser_thread_impl.h" | 7 #include "content/browser/browser_thread_impl.h" |
| 8 #include "content/browser/speech/google_one_shot_remote_engine.h" | 8 #include "content/browser/speech/google_one_shot_remote_engine.h" |
| 9 #include "content/browser/speech/speech_recognizer_impl.h" | 9 #include "content/browser/speech/speech_recognizer_impl.h" |
| 10 #include "content/public/browser/speech_recognition_event_listener.h" | 10 #include "content/public/browser/speech_recognition_event_listener.h" |
| 11 #include "content/test/test_url_fetcher_factory.h" | 11 #include "content/public/test/test_url_fetcher_factory.h" |
| 12 #include "media/audio/audio_manager.h" | 12 #include "media/audio/audio_manager.h" |
| 13 #include "media/audio/fake_audio_input_stream.h" | 13 #include "media/audio/fake_audio_input_stream.h" |
| 14 #include "media/audio/fake_audio_output_stream.h" | 14 #include "media/audio/fake_audio_output_stream.h" |
| 15 #include "media/audio/test_audio_input_controller_factory.h" | 15 #include "media/audio/test_audio_input_controller_factory.h" |
| 16 #include "net/base/net_errors.h" | 16 #include "net/base/net_errors.h" |
| 17 #include "net/url_request/url_request_status.h" | 17 #include "net/url_request/url_request_status.h" |
| 18 #include "testing/gtest/include/gtest/gtest.h" | 18 #include "testing/gtest/include/gtest/gtest.h" |
| 19 | 19 |
| 20 using base::MessageLoopProxy; | 20 using base::MessageLoopProxy; |
| 21 using content::BrowserThread; | 21 using content::BrowserThread; |
| (...skipping 527 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 549 | 549 |
| 550 EXPECT_EQ(content::SPEECH_RECOGNITION_ERROR_NONE, error_); | 550 EXPECT_EQ(content::SPEECH_RECOGNITION_ERROR_NONE, error_); |
| 551 EXPECT_FALSE(audio_ended_); | 551 EXPECT_FALSE(audio_ended_); |
| 552 EXPECT_FALSE(recognition_ended_); | 552 EXPECT_FALSE(recognition_ended_); |
| 553 recognizer_->AbortRecognition(); | 553 recognizer_->AbortRecognition(); |
| 554 MessageLoop::current()->RunAllPending(); | 554 MessageLoop::current()->RunAllPending(); |
| 555 CheckFinalEventsConsistency(); | 555 CheckFinalEventsConsistency(); |
| 556 } | 556 } |
| 557 | 557 |
| 558 } // namespace speech | 558 } // namespace speech |
| OLD | NEW |