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

Side by Side Diff: content/browser/media/session/media_session_uma_helper_unittest.cc

Issue 1698933004: Make MediaSession a runtime-enabled feature on Desktop. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 9 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "content/browser/media/android/media_session_uma_helper.h" 5 #include "content/browser/media/session/media_session_uma_helper.h"
6 6
7 #include "base/metrics/histogram_samples.h" 7 #include "base/metrics/histogram_samples.h"
8 #include "base/test/histogram_tester.h" 8 #include "base/test/histogram_tester.h"
9 #include "base/test/simple_test_clock.h" 9 #include "base/test/simple_test_clock.h"
10 #include "testing/gtest/include/gtest/gtest.h" 10 #include "testing/gtest/include/gtest/gtest.h"
11 11
12 namespace content { 12 namespace content {
13 13
14 using MediaSessionSuspendedSource = 14 using MediaSessionSuspendedSource =
15 MediaSessionUmaHelper::MediaSessionSuspendedSource; 15 MediaSessionUmaHelper::MediaSessionSuspendedSource;
(...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after
306 media_session_uma_helper().OnSessionInactive(); 306 media_session_uma_helper().OnSessionInactive();
307 307
308 // If the session is already inactive, OnSessionInactive() calls are ignored. 308 // If the session is already inactive, OnSessionInactive() calls are ignored.
309 scoped_ptr<base::HistogramSamples> samples( 309 scoped_ptr<base::HistogramSamples> samples(
310 GetHistogramSamplesSinceTestStart("Media.Session.ActiveTime")); 310 GetHistogramSamplesSinceTestStart("Media.Session.ActiveTime"));
311 EXPECT_EQ(1, samples->TotalCount()); 311 EXPECT_EQ(1, samples->TotalCount());
312 EXPECT_EQ(1, samples->GetCount(3000)); 312 EXPECT_EQ(1, samples->GetCount(3000));
313 } 313 }
314 314
315 } // namespace content 315 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/media/session/media_session_uma_helper.cc ('k') | content/browser/media/session/mock_media_session_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698