public void TestTraktCalendarAllNewShowsRequestUriParamsWithoutStartDateAndDays() { var request = new TraktCalendarAllNewShowsRequest(null); var uriParams = request.GetUriPathParameters(); uriParams.Should().NotBeNull().And.BeEmpty(); }
public void TestTraktCalendarAllNewShowsRequestUriParamsWithStartDate() { var startDate = DateTime.Now; var request = new TraktCalendarAllNewShowsRequest(null) { StartDate = startDate }; var uriParams = request.GetUriPathParameters(); uriParams.Should().NotBeNull().And.NotBeEmpty().And.HaveCount(1); uriParams.Should().Contain("start_date", startDate.ToTraktDateString()); }
public void TestTraktCalendarAllNewShowsRequestUriParamsWithDays() { var startDate = DateTime.Now; var days = 14; var request = new TraktCalendarAllNewShowsRequest(null) { Days = days }; var uriParams = request.GetUriPathParameters(); uriParams.Should().NotBeNull().And.NotBeEmpty().And.HaveCount(2); uriParams.Should().Contain(new Dictionary <string, object> { ["start_date"] = startDate.ToTraktDateString(), ["days"] = days }); }