Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(917)

Unified Diff: media/base/pipeline_unittest.cc

Issue 16823003: Replace erroneous use of base::Time with base::TimeTicks throughout media code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: s/PresubmitPromptWarning/PresubmitPromptOrNotify/ Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/base/pipeline.cc ('k') | media/filters/audio_renderer_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/pipeline_unittest.cc
diff --git a/media/base/pipeline_unittest.cc b/media/base/pipeline_unittest.cc
index 778a036daa7ffa5d7d505578ed7e688a6f8e7292..a121ee476911d08e097838024e4daa7f0a340b2d 100644
--- a/media/base/pipeline_unittest.cc
+++ b/media/base/pipeline_unittest.cc
@@ -7,7 +7,7 @@
#include "base/bind.h"
#include "base/message_loop.h"
#include "base/stl_util.h"
-#include "base/test/simple_test_clock.h"
+#include "base/test/simple_test_tick_clock.h"
#include "base/threading/simple_thread.h"
#include "base/time/clock.h"
#include "media/base/clock.h"
@@ -286,7 +286,7 @@ class PipelineTest : public ::testing::Test {
// Fixture members.
StrictMock<CallbackHelper> callbacks_;
- base::SimpleTestClock test_clock_;
+ base::SimpleTestTickClock test_tick_clock_;
base::MessageLoop message_loop_;
scoped_ptr<Pipeline> pipeline_;
@@ -606,7 +606,7 @@ TEST_F(PipelineTest, AudioStreamShorterThanVideo) {
// Replace the clock so we can simulate wallclock time advancing w/o using
// Sleep().
- pipeline_->SetClockForTesting(new Clock(&test_clock_));
+ pipeline_->SetClockForTesting(new Clock(&test_tick_clock_));
InitializeDemuxer(&streams, duration);
InitializeAudioRenderer(audio_stream(), false);
@@ -627,7 +627,7 @@ TEST_F(PipelineTest, AudioStreamShorterThanVideo) {
// Verify that the clock doesn't advance since it hasn't been started by
// a time update from the audio stream.
int64 start_time = pipeline_->GetMediaTime().ToInternalValue();
- test_clock_.Advance(base::TimeDelta::FromMilliseconds(100));
+ test_tick_clock_.Advance(base::TimeDelta::FromMilliseconds(100));
EXPECT_EQ(pipeline_->GetMediaTime().ToInternalValue(), start_time);
// Signal end of audio stream.
@@ -636,7 +636,7 @@ TEST_F(PipelineTest, AudioStreamShorterThanVideo) {
// Verify that the clock advances.
start_time = pipeline_->GetMediaTime().ToInternalValue();
- test_clock_.Advance(base::TimeDelta::FromMilliseconds(100));
+ test_tick_clock_.Advance(base::TimeDelta::FromMilliseconds(100));
EXPECT_GT(pipeline_->GetMediaTime().ToInternalValue(), start_time);
// Signal end of video stream and make sure OnEnded() callback occurs.
« no previous file with comments | « media/base/pipeline.cc ('k') | media/filters/audio_renderer_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698