OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "chrome/common/metrics/variations/variations_associated_data.h" | 5 #include "components/variations/variations_associated_data.h" |
6 | 6 |
7 #include "base/metrics/field_trial.h" | 7 #include "base/metrics/field_trial.h" |
8 #include "testing/gtest/include/gtest/gtest.h" | 8 #include "testing/gtest/include/gtest/gtest.h" |
9 | 9 |
10 namespace chrome_variations { | 10 namespace chrome_variations { |
11 | 11 |
12 namespace { | 12 namespace { |
13 | 13 |
14 const VariationID TEST_VALUE_A = 3300200; | 14 const VariationID TEST_VALUE_A = 3300200; |
15 const VariationID TEST_VALUE_B = 3300201; | 15 const VariationID TEST_VALUE_B = 3300201; |
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
301 scoped_refptr<base::FieldTrial> trial( | 301 scoped_refptr<base::FieldTrial> trial( |
302 CreateFieldTrial(kTrialName, 100, "A", NULL)); | 302 CreateFieldTrial(kTrialName, 100, "A", NULL)); |
303 ASSERT_FALSE(IsFieldTrialActive(kTrialName)); | 303 ASSERT_FALSE(IsFieldTrialActive(kTrialName)); |
304 | 304 |
305 std::map<std::string, std::string> params; | 305 std::map<std::string, std::string> params; |
306 EXPECT_EQ(std::string(), GetVariationParamValue(kTrialName, "x")); | 306 EXPECT_EQ(std::string(), GetVariationParamValue(kTrialName, "x")); |
307 ASSERT_TRUE(IsFieldTrialActive(kTrialName)); | 307 ASSERT_TRUE(IsFieldTrialActive(kTrialName)); |
308 } | 308 } |
309 | 309 |
310 } // namespace chrome_variations | 310 } // namespace chrome_variations |
OLD | NEW |