fix: disable tests broken by daylight savings (#10414)

This commit is contained in:
Spike Curtis 2023-10-30 10:44:30 +04:00 committed by GitHub
parent 3b50530a63
commit c2e3648484
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 17 additions and 16 deletions

View File

@ -209,25 +209,26 @@ func TestTimezoneOffsets(t *testing.T) {
ExpectedOffset int
}{
{
Name: "UTX",
Name: "UTC",
Loc: time.UTC,
ExpectedOffset: 0,
},
{
Name: "Eastern",
Loc: must(time.LoadLocation("America/New_York")),
ExpectedOffset: -4,
},
{
Name: "Central",
Loc: must(time.LoadLocation("America/Chicago")),
ExpectedOffset: -5,
},
{
Name: "Ireland",
Loc: must(time.LoadLocation("Europe/Dublin")),
ExpectedOffset: 1,
},
// The following test cases are broken re: daylight savings
//{
// Name: "Eastern",
// Loc: must(time.LoadLocation("America/New_York")),
// ExpectedOffset: -4,
//},
//{
// Name: "Central",
// Loc: must(time.LoadLocation("America/Chicago")),
// ExpectedOffset: -5,
//},
//{
// Name: "Ireland",
// Loc: must(time.LoadLocation("Europe/Dublin")),
// ExpectedOffset: 1,
//},
{
Name: "HalfHourTz",
// This timezone is +6:30, but the function rounds to the nearest hour.