Make castv2 performance test work.
[chromium-blink-merge.git] / chrome / browser / metrics / signin_status_metrics_provider_chromeos_unittest.cc
blob2448169aded3a34f5fe6c17af709edfae169a340
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
3 // found in the LICENSE file.
5 #include "chrome/browser/metrics/signin_status_metrics_provider_chromeos.h"
7 #include <string>
9 #include "base/files/file_path.h"
10 #include "testing/gtest/include/gtest/gtest.h"
12 TEST(SigninStatusMetricsProviderChromeOS, ComputeSigninStatusToUpload) {
13 SigninStatusMetricsProviderChromeOS metrics_provider =
14 SigninStatusMetricsProviderChromeOS();
16 SigninStatusMetricsProviderBase::SigninStatus status_to_upload =
17 metrics_provider.ComputeSigninStatusToUpload(
18 SigninStatusMetricsProviderBase::ALL_PROFILES_SIGNED_IN, true);
19 EXPECT_EQ(SigninStatusMetricsProviderBase::ALL_PROFILES_SIGNED_IN,
20 status_to_upload);
22 status_to_upload = metrics_provider.ComputeSigninStatusToUpload(
23 SigninStatusMetricsProviderBase::ALL_PROFILES_NOT_SIGNED_IN, false);
24 EXPECT_EQ(SigninStatusMetricsProviderBase::ALL_PROFILES_NOT_SIGNED_IN,
25 status_to_upload);
27 status_to_upload = metrics_provider.ComputeSigninStatusToUpload(
28 SigninStatusMetricsProviderBase::ALL_PROFILES_NOT_SIGNED_IN, true);
29 EXPECT_EQ(SigninStatusMetricsProviderBase::MIXED_SIGNIN_STATUS,
30 status_to_upload);
32 status_to_upload = metrics_provider.ComputeSigninStatusToUpload(
33 SigninStatusMetricsProviderBase::ALL_PROFILES_SIGNED_IN, false);
34 EXPECT_EQ(SigninStatusMetricsProviderBase::ERROR_GETTING_SIGNIN_STATUS,
35 status_to_upload);