OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/test/ui/ui_test.h" | 5 #include "chrome/test/ui/ui_test.h" |
6 | 6 |
7 #include "chrome/app/chrome_dll_resource.h" | 7 #include "chrome/app/chrome_dll_resource.h" |
8 #include "chrome/browser/chrome_thread.h" | 8 #include "chrome/browser/chrome_thread.h" |
9 #include "chrome/browser/dom_ui/new_tab_ui.h" | 9 #include "chrome/browser/dom_ui/new_tab_ui.h" |
10 #include "chrome/browser/pref_value_store.h" | 10 #include "chrome/browser/prefs/pref_value_store.h" |
11 #include "chrome/common/json_pref_store.h" | 11 #include "chrome/common/json_pref_store.h" |
12 #include "chrome/common/pref_names.h" | 12 #include "chrome/common/pref_names.h" |
13 #include "chrome/test/automation/browser_proxy.h" | 13 #include "chrome/test/automation/browser_proxy.h" |
14 #include "chrome/test/automation/tab_proxy.h" | 14 #include "chrome/test/automation/tab_proxy.h" |
15 #include "chrome/test/automation/window_proxy.h" | 15 #include "chrome/test/automation/window_proxy.h" |
16 #include "chrome/test/testing_pref_service.h" | 16 #include "chrome/test/testing_pref_service.h" |
17 | 17 |
18 class NewTabUITest : public UITest { | 18 class NewTabUITest : public UITest { |
19 public: | 19 public: |
20 NewTabUITest() { | 20 NewTabUITest() { |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 ASSERT_EQ(0, prefs->GetInteger(prefs::kNTPPrefVersion)); | 88 ASSERT_EQ(0, prefs->GetInteger(prefs::kNTPPrefVersion)); |
89 | 89 |
90 bool migrated = NewTabUI::UpdateUserPrefsVersion(prefs.get()); | 90 bool migrated = NewTabUI::UpdateUserPrefsVersion(prefs.get()); |
91 ASSERT_TRUE(migrated); | 91 ASSERT_TRUE(migrated); |
92 ASSERT_EQ(NewTabUI::current_pref_version(), | 92 ASSERT_EQ(NewTabUI::current_pref_version(), |
93 prefs->GetInteger(prefs::kNTPPrefVersion)); | 93 prefs->GetInteger(prefs::kNTPPrefVersion)); |
94 | 94 |
95 migrated = NewTabUI::UpdateUserPrefsVersion(prefs.get()); | 95 migrated = NewTabUI::UpdateUserPrefsVersion(prefs.get()); |
96 ASSERT_FALSE(migrated); | 96 ASSERT_FALSE(migrated); |
97 } | 97 } |
OLD | NEW |