| OLD | NEW |
| (Empty) |
| 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. | |
| 4 | |
| 5 #include "components/password_manager/core/browser/password_bubble_experiment.h" | |
| 6 | |
| 7 #include "base/files/scoped_temp_dir.h" | |
| 8 #include "base/metrics/field_trial.h" | |
| 9 #include "chrome/test/base/testing_profile.h" | |
| 10 #include "components/variations/entropy_provider.h" | |
| 11 #include "components/variations/variations_associated_data.h" | |
| 12 #include "content/public/test/test_browser_thread_bundle.h" | |
| 13 #include "testing/gtest/include/gtest/gtest.h" | |
| 14 | |
| 15 class PasswordBubbleExperimentTest : public testing::Test { | |
| 16 public: | |
| 17 void SetUp() override { | |
| 18 ASSERT_TRUE(temp_dir_.CreateUniqueTempDir()); | |
| 19 profile_.reset(new TestingProfile(temp_dir_.path())); | |
| 20 | |
| 21 field_trial_list_.reset(new base::FieldTrialList( | |
| 22 new metrics::SHA1EntropyProvider("foo"))); | |
| 23 } | |
| 24 | |
| 25 void TearDown() override { | |
| 26 variations::testing::ClearAllVariationParams(); | |
| 27 } | |
| 28 | |
| 29 PrefService* prefs() { return profile_->GetPrefs(); } | |
| 30 | |
| 31 private: | |
| 32 content::TestBrowserThreadBundle thread_bundle_; | |
| 33 base::ScopedTempDir temp_dir_; | |
| 34 std::unique_ptr<TestingProfile> profile_; | |
| 35 std::unique_ptr<base::FieldTrialList> field_trial_list_; | |
| 36 }; | |
| 37 | |
| 38 // TODO(vasilii): add tests once there is a smart bubble. | |
| OLD | NEW |