public async Task GetEventsFixture() { var cb = new CalendarBusiness(); var items = await cb.GetEvents("*****@*****.**"); items.Should().NotBeNull(); items.Items.Should().HaveCount(c => c > 0); }
public virtual async Task <ActionResult> Get(string id, bool all = true, bool bust = false) { var cacheKey = string.Format("{0}-{1}-{2}", "calenderitems", id, all.ToString()); if (bust) { Cache.Remove(cacheKey); } var events = await Cache.GetOrSet(cacheKey, async() => await CalendarBusiness.GetEvents(id, all)); return(Json(events, JsonRequestBehavior.AllowGet)); }