public void TestTraktCalendarUserNewShowsRequestUriParamsWithoutStartDateAndDays() { var request = new TraktCalendarUserNewShowsRequest(null); var uriParams = request.GetUriPathParameters(); uriParams.Should().NotBeNull().And.BeEmpty(); }
public void TestTraktCalendarUserNewShowsRequestUriParamsWithStartDate() { var startDate = DateTime.Now; var request = new TraktCalendarUserNewShowsRequest(null) { StartDate = startDate }; var uriParams = request.GetUriPathParameters(); uriParams.Should().NotBeNull().And.NotBeEmpty().And.HaveCount(1); uriParams.Should().Contain("start_date", startDate.ToTraktDateString()); }
public void TestTraktCalendarUserNewShowsRequestUriParamsWithDays() { var startDate = DateTime.Now; var days = 14; var request = new TraktCalendarUserNewShowsRequest(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 }); }