| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/browser/extensions/extension_prefs_unittest.h" | 5 #include "chrome/browser/extensions/extension_prefs_unittest.h" |
| 6 #include "chrome/browser/extensions/extension_sorting.h" | 6 #include "chrome/browser/extensions/extension_sorting.h" |
| 7 #include "chrome/common/extensions/extension_manifest_constants.h" | 7 #include "chrome/common/extensions/extension_manifest_constants.h" |
| 8 #include "testing/gtest/include/gtest/gtest.h" | 8 #include "testing/gtest/include/gtest/gtest.h" |
| 9 | 9 |
| 10 using extensions::Extension; |
| 11 |
| 10 namespace keys = extension_manifest_keys; | 12 namespace keys = extension_manifest_keys; |
| 11 | 13 |
| 12 class ExtensionSortingTest : public ExtensionPrefsTest { | 14 class ExtensionSortingTest : public ExtensionPrefsTest { |
| 13 protected: | 15 protected: |
| 14 ExtensionSorting* extension_sorting() { | 16 ExtensionSorting* extension_sorting() { |
| 15 return prefs()->extension_sorting(); | 17 return prefs()->extension_sorting(); |
| 16 } | 18 } |
| 17 }; | 19 }; |
| 18 | 20 |
| 19 class ExtensionSortingAppLocation : public ExtensionSortingTest { | 21 class ExtensionSortingAppLocation : public ExtensionSortingTest { |
| (...skipping 730 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 750 extension_sorting->SetPageOrdinal(app1_->id(), page_three); | 752 extension_sorting->SetPageOrdinal(app1_->id(), page_three); |
| 751 EXPECT_EQ(2, extension_sorting->PageStringOrdinalAsInteger(page_three)); | 753 EXPECT_EQ(2, extension_sorting->PageStringOrdinalAsInteger(page_three)); |
| 752 | 754 |
| 753 StringOrdinal page_six = extension_sorting->PageIntegerAsStringOrdinal(5); | 755 StringOrdinal page_six = extension_sorting->PageIntegerAsStringOrdinal(5); |
| 754 extension_sorting->SetPageOrdinal(app1_->id(), page_six); | 756 extension_sorting->SetPageOrdinal(app1_->id(), page_six); |
| 755 EXPECT_EQ(5, extension_sorting->PageStringOrdinalAsInteger(page_six)); | 757 EXPECT_EQ(5, extension_sorting->PageStringOrdinalAsInteger(page_six)); |
| 756 } | 758 } |
| 757 }; | 759 }; |
| 758 TEST_F(ExtensionSortingMakesFillerOrdinals, | 760 TEST_F(ExtensionSortingMakesFillerOrdinals, |
| 759 ExtensionSortingMakesFillerOrdinals) {} | 761 ExtensionSortingMakesFillerOrdinals) {} |
| OLD | NEW |