-
Notifications
You must be signed in to change notification settings - Fork 135
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c4665ca
commit f7d6de8
Showing
6 changed files
with
116 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
#include "time_zone_with_expect_value.h" | ||
|
||
#if !defined(_WIN32) | ||
|
||
const std::array<TimeZoneWithExpectValue, 12> timeZonesWithExpectedTimeValues{ | ||
TimeZoneWithExpectValue("UTC", 0, 0), | ||
TimeZoneWithExpectValue("America/Puerto_Rico", 240, 240), | ||
TimeZoneWithExpectValue("America/New_York", 300, 300), | ||
TimeZoneWithExpectValue("US/Eastern", 300, 300), | ||
TimeZoneWithExpectValue("America/Chicago", 360, 360), | ||
TimeZoneWithExpectValue("US/Mountain", 420, 420), | ||
TimeZoneWithExpectValue("US/Pacific", 480, 480), | ||
TimeZoneWithExpectValue("US/Alaska", 540, 540), | ||
TimeZoneWithExpectValue("Pacific/Honolulu", 600, 600), | ||
TimeZoneWithExpectValue("US/Samoa", 660, 660), | ||
TimeZoneWithExpectValue("Australia/South", -570, -570), | ||
TimeZoneWithExpectValue("Pacific/Guam", -600, -600)}; | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
#include "starboard/time_zone.h" | ||
|
||
#include <array> | ||
#include <gmock/gmock.h> | ||
|
||
struct TimeZoneWithExpectValue { | ||
TimeZoneWithExpectValue(std::string timeZoneName_, | ||
SbTimeZone expectedStandardValue_, | ||
SbTimeZone expectedDaylightValue_) | ||
: timeZoneName{timeZoneName_}, | ||
expectedStandardValue{expectedStandardValue_}, | ||
expectedDaylightValue{expectedDaylightValue_} {} | ||
|
||
std::string timeZoneName; | ||
|
||
SbTimeZone expectedStandardValue; | ||
SbTimeZone expectedDaylightValue; | ||
}; | ||
|
||
extern const std::array<TimeZoneWithExpectValue, 12> timeZonesWithExpectedTimeValues; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
#include "time_zone_with_expect_value.h" | ||
|
||
#if defined(_WIN32) | ||
|
||
const std::array<TimeZoneWithExpectValue, 12> timeZonesWithExpectedTimeValues{ | ||
TimeZoneWithExpectValue("UTC", 0, 0), | ||
TimeZoneWithExpectValue("Atlantic Standard Time", 240, 180), | ||
TimeZoneWithExpectValue("Eastern Standard Time", 300, 240), | ||
TimeZoneWithExpectValue("Central Standard Time", 360, 300), | ||
TimeZoneWithExpectValue("Mountain Standard Time", 420, 360), | ||
TimeZoneWithExpectValue("Pacific Standard Time", 480, 420), | ||
TimeZoneWithExpectValue("Yukon Standard Time", 420, 420), | ||
TimeZoneWithExpectValue("Samoa Standard Time", -840, -840), | ||
TimeZoneWithExpectValue("China Standard Time", -480, -480), | ||
TimeZoneWithExpectValue("Central European Standard Time", -60, -120), | ||
TimeZoneWithExpectValue("Omsk Standard Time", -360, -360), | ||
TimeZoneWithExpectValue("Cen. Australia Standard Time", -570, -630)}; | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters