| OLD | NEW |
| 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 <stddef.h> |
| 5 #include <stdint.h> | 6 #include <stdint.h> |
| 6 | 7 |
| 7 #include "base/bind.h" | 8 #include "base/bind.h" |
| 9 #include "base/macros.h" |
| 8 #include "base/test/simple_test_tick_clock.h" | 10 #include "base/test/simple_test_tick_clock.h" |
| 9 #include "media/cast/sender/congestion_control.h" | 11 #include "media/cast/sender/congestion_control.h" |
| 10 #include "media/cast/test/fake_single_thread_task_runner.h" | 12 #include "media/cast/test/fake_single_thread_task_runner.h" |
| 11 #include "testing/gtest/include/gtest/gtest.h" | 13 #include "testing/gtest/include/gtest/gtest.h" |
| 12 | 14 |
| 13 namespace media { | 15 namespace media { |
| 14 namespace cast { | 16 namespace cast { |
| 15 | 17 |
| 16 static const int kMaxBitrateConfigured = 5000000; | 18 static const int kMaxBitrateConfigured = 5000000; |
| 17 static const int kMinBitrateConfigured = 500000; | 19 static const int kMinBitrateConfigured = 500000; |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 128 testing_clock_.NowTicks() + base::TimeDelta::FromMilliseconds(300), | 130 testing_clock_.NowTicks() + base::TimeDelta::FromMilliseconds(300), |
| 129 base::TimeDelta::FromMilliseconds(300), | 131 base::TimeDelta::FromMilliseconds(300), |
| 130 soft_max_bitrate); | 132 soft_max_bitrate); |
| 131 EXPECT_NEAR(safe_bitrate / kTargetEmptyBufferFraction * 1 / 3, | 133 EXPECT_NEAR(safe_bitrate / kTargetEmptyBufferFraction * 1 / 3, |
| 132 bitrate, | 134 bitrate, |
| 133 safe_bitrate * 0.05); | 135 safe_bitrate * 0.05); |
| 134 } | 136 } |
| 135 | 137 |
| 136 } // namespace cast | 138 } // namespace cast |
| 137 } // namespace media | 139 } // namespace media |
| OLD | NEW |