| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/chromeos/status/clock_menu_button.h" | 5 #include "chrome/browser/chromeos/status/clock_menu_button.h" |
| 6 | 6 |
| 7 #include "base/memory/scoped_ptr.h" | 7 #include "base/memory/scoped_ptr.h" |
| 8 #include "chrome/browser/chromeos/cros/cros_library.h" | 8 #include "chrome/browser/chromeos/cros/cros_library.h" |
| 9 #include "chrome/browser/chromeos/frame/browser_view.h" | 9 #include "chrome/browser/chromeos/frame/browser_view.h" |
| 10 #include "chrome/browser/chromeos/status/status_area_view.h" | 10 #include "chrome/browser/chromeos/status/status_area_view.h" |
| 11 #include "chrome/browser/chromeos/system/timezone_settings.h" | 11 #include "chrome/browser/chromeos/system/timezone_settings.h" |
| 12 #include "chrome/browser/chromeos/view_ids.h" | 12 #include "chrome/browser/chromeos/view_ids.h" |
| 13 #include "chrome/browser/prefs/pref_member.h" | 13 #include "chrome/browser/prefs/pref_member.h" |
| 14 #include "chrome/browser/ui/browser.h" | 14 #include "chrome/browser/ui/browser.h" |
| 15 #include "chrome/browser/ui/browser_window.h" | 15 #include "chrome/browser/ui/browser_window.h" |
| 16 #include "chrome/test/base/in_process_browser_test.h" | 16 #include "chrome/test/base/in_process_browser_test.h" |
| 17 #include "testing/gtest/include/gtest/gtest.h" | 17 #include "testing/gtest/include/gtest/gtest.h" |
| 18 #include "unicode/calendar.h" | 18 #include "unicode/calendar.h" |
| 19 #include "unicode/timezone.h" | 19 #include "unicode/timezone.h" |
| 20 | 20 |
| 21 #if defined(USE_AURA) | 21 #if defined(USE_AURA) |
| 22 #include "chrome/browser/ui/views/aura/chrome_shell_delegate.h" | 22 #include "chrome/browser/ui/views/ash/chrome_shell_delegate.h" |
| 23 #endif | 23 #endif |
| 24 | 24 |
| 25 namespace chromeos { | 25 namespace chromeos { |
| 26 | 26 |
| 27 class ClockMenuButtonTest : public InProcessBrowserTest { | 27 class ClockMenuButtonTest : public InProcessBrowserTest { |
| 28 protected: | 28 protected: |
| 29 ClockMenuButtonTest() : InProcessBrowserTest() {} | 29 ClockMenuButtonTest() : InProcessBrowserTest() {} |
| 30 virtual void SetUpInProcessBrowserTestFixture() { | 30 virtual void SetUpInProcessBrowserTestFixture() { |
| 31 // This test requires actual libcros, but InProcessBrowserTest has set | 31 // This test requires actual libcros, but InProcessBrowserTest has set |
| 32 // to use stub, so reset it here. | 32 // to use stub, so reset it here. |
| (...skipping 21 matching lines...) Expand all Loading... |
| 54 system::TimezoneSettings::GetInstance()->SetTimezone(*timezone_first); | 54 system::TimezoneSettings::GetInstance()->SetTimezone(*timezone_first); |
| 55 string16 text_before = clock->text(); | 55 string16 text_before = clock->text(); |
| 56 scoped_ptr<icu::TimeZone> timezone_second(icu::TimeZone::createTimeZone( | 56 scoped_ptr<icu::TimeZone> timezone_second(icu::TimeZone::createTimeZone( |
| 57 icu::UnicodeString::fromUTF8("Pacific/Samoa"))); | 57 icu::UnicodeString::fromUTF8("Pacific/Samoa"))); |
| 58 system::TimezoneSettings::GetInstance()->SetTimezone(*timezone_second); | 58 system::TimezoneSettings::GetInstance()->SetTimezone(*timezone_second); |
| 59 string16 text_after = clock->text(); | 59 string16 text_after = clock->text(); |
| 60 EXPECT_NE(text_before, text_after); | 60 EXPECT_NE(text_before, text_after); |
| 61 } | 61 } |
| 62 | 62 |
| 63 } // namespace chromeos | 63 } // namespace chromeos |
| OLD | NEW |