public async Task CanParseEvents() { var file = new FileInfo(Path.Combine(AppContext.BaseDirectory, "Data", "basic.ics")); var events = await UTF8Parser.LoadAndParseFeed(file); Assert.Equal(1159, events.Count); }
public async Task CanParseInstants() { var file = new FileInfo(Path.Combine(AppContext.BaseDirectory, "Data", "basic.ics")); var events = await UTF8Parser.LoadAndParseFeed(file); Assert.NotEmpty(events.Where(ev => ev.Start != default || ev.End != default )); }
public async Task CanParseTextProperties() { var file = new FileInfo(Path.Combine(AppContext.BaseDirectory, "Data", "basic.ics")); var events = await UTF8Parser.LoadAndParseFeed(file); Assert.NotEmpty(events.Where(ev => !string.IsNullOrWhiteSpace(ev.UId) || !string.IsNullOrWhiteSpace(ev.Summary) )); }
public Task <List <Event> > ParseEventWithPipes() { return(UTF8Parser.LoadAndParseFeed(file)); }