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

Side by Side Diff: media/cast/video_sender/video_encoder_impl_unittest.cc

Issue 210303003: Cast: Remove LoggingStats in favor of event subscribers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix compile Created 6 years, 8 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "base/bind.h" 7 #include "base/bind.h"
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "media/base/video_frame.h" 10 #include "media/base/video_frame.h"
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 87
88 virtual ~VideoEncoderImplTest() {} 88 virtual ~VideoEncoderImplTest() {}
89 89
90 virtual void SetUp() OVERRIDE { 90 virtual void SetUp() OVERRIDE {
91 testing_clock_ = new base::SimpleTestTickClock(); 91 testing_clock_ = new base::SimpleTestTickClock();
92 task_runner_ = new test::FakeSingleThreadTaskRunner(testing_clock_); 92 task_runner_ = new test::FakeSingleThreadTaskRunner(testing_clock_);
93 cast_environment_ = 93 cast_environment_ =
94 new CastEnvironment(scoped_ptr<base::TickClock>(testing_clock_).Pass(), 94 new CastEnvironment(scoped_ptr<base::TickClock>(testing_clock_).Pass(),
95 task_runner_, 95 task_runner_,
96 task_runner_, 96 task_runner_,
97 task_runner_, 97 task_runner_);
98 GetDefaultCastSenderLoggingConfig());
99 } 98 }
100 99
101 virtual void TearDown() OVERRIDE { 100 virtual void TearDown() OVERRIDE {
102 video_encoder_.reset(); 101 video_encoder_.reset();
103 task_runner_->RunTasks(); 102 task_runner_->RunTasks();
104 } 103 }
105 104
106 void Configure(uint8 max_unacked_frames) { 105 void Configure(uint8 max_unacked_frames) {
107 video_encoder_.reset(new VideoEncoderImpl( 106 video_encoder_.reset(new VideoEncoderImpl(
108 cast_environment_, video_config_, max_unacked_frames)); 107 cast_environment_, video_config_, max_unacked_frames));
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
251 for (int i = 5; i < 17; ++i) { 250 for (int i = 5; i < 17; ++i) {
252 test_video_encoder_callback_->SetExpectedResult(false, i, 4, capture_time); 251 test_video_encoder_callback_->SetExpectedResult(false, i, 4, capture_time);
253 EXPECT_TRUE(video_encoder_->EncodeVideoFrame( 252 EXPECT_TRUE(video_encoder_->EncodeVideoFrame(
254 video_frame_, capture_time, frame_encoded_callback)); 253 video_frame_, capture_time, frame_encoded_callback));
255 task_runner_->RunTasks(); 254 task_runner_->RunTasks();
256 } 255 }
257 } 256 }
258 257
259 } // namespace cast 258 } // namespace cast
260 } // namespace media 259 } // namespace media
OLDNEW
« no previous file with comments | « media/cast/video_sender/external_video_encoder_unittest.cc ('k') | media/cast/video_sender/video_sender_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698