The Free Software Media System - Server Backend & API
Fix failing unit tests on machines where the local timezone offset is far enough away from the test data day to be off by a day.
Shane Powell333046533784
diff --git a/tests/Jellyfin.LiveTv.Tests/Listings/XmlTvListingsProviderTests.cs b/tests/Jellyfin.LiveTv.Tests/Listings/XmlTvListingsProviderTests.csindex 0fb7894e51..332658f674 100644--- a/tests/Jellyfin.LiveTv.Tests/Listings/XmlTvListingsProviderTests.cs+++ b/tests/Jellyfin.LiveTv.Tests/Listings/XmlTvListingsProviderTests.cs@@ -54,7 +54,7 @@ public class XmlTvListingsProviderTestsPath = path};- var startDate = new DateTime(2022, 11, 4);+ var startDate = new DateTime(2022, 11, 4, 0, 0, 0, 0, DateTimeKind.Utc);var programs = await _xmlTvListingsProvider.GetProgramsAsync(info, "3297", startDate, startDate.AddDays(1), CancellationToken.None);var programsList = programs.ToList();Assert.Single(programsList);@@ -78,7 +78,7 @@ public class XmlTvListingsProviderTestsPath = path};- var startDate = new DateTime(2022, 11, 4);+ var startDate = new DateTime(2022, 11, 4, 0, 0, 0, DateTimeKind.Utc);var programs = await _xmlTvListingsProvider.GetProgramsAsync(info, "3297", startDate, startDate.AddDays(1), CancellationToken.None);var programsList = programs.ToList();Assert.Single(programsList);