Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5242)

Unified Diff: chrome/browser/chromeos/status/clock_menu_button_browsertest.cc

Issue 3204001: Fixed flakyness of ClockMenuButtonTest.TimezoneTest.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/status/clock_menu_button_browsertest.cc
===================================================================
--- chrome/browser/chromeos/status/clock_menu_button_browsertest.cc (revision 57046)
+++ chrome/browser/chromeos/status/clock_menu_button_browsertest.cc (working copy)
@@ -35,13 +35,18 @@
IN_PROC_BROWSER_TEST_F(ClockMenuButtonTest, TimezoneTest) {
ClockMenuButton* clock = GetClockMenuButton();
ASSERT_TRUE(clock != NULL);
+
// Update timezone and make sure clock text changes.
+ scoped_ptr<icu::TimeZone> timezone_first(icu::TimeZone::createTimeZone(
+ icu::UnicodeString::fromUTF8("Asia/Hong_Kong")));
+ CrosLibrary::Get()->GetSystemLibrary()->SetTimezone(timezone_first.get());
std::wstring text_before = clock->text();
- scoped_ptr<icu::TimeZone> timezone(icu::TimeZone::createTimeZone(
- icu::UnicodeString::fromUTF8("Asia/Hong_Kong")));
- CrosLibrary::Get()->GetSystemLibrary()->SetTimezone(timezone.get());
+ scoped_ptr<icu::TimeZone> timezone_second(icu::TimeZone::createTimeZone(
+ icu::UnicodeString::fromUTF8("Pacific/Samoa")));
+ CrosLibrary::Get()->GetSystemLibrary()->SetTimezone(timezone_second.get());
std::wstring text_after = clock->text();
EXPECT_NE(text_before, text_after);
+
}
} // namespace chromeos
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698