public void NotYetImplemented_DoesntRemoveDuplicatesAfterRemove() { source = new TestObservableCollection <string>("44".Select(i => i.ToString())); buffer = source.AsObservableQuery().OrderBy(letter => letter).AsObservableQuery().ToObservableView().ToBuffer(); source.RemoveAt(0); DoAssert(); }
public void SetupFilters() { source = new TestObservableCollection <int>() { 1, 2, 3, 4, }; value = source.AsObservableQuery() .Observe(i => i.Max()); }
public void SetUp() { source = new TestObservableCollection <List <string> >() { new[] { "1" }.ToList(), new[] { "2" }.ToList(), new[] { "3" }.ToList() }; buffer = source.AsObservableQuery().SelectMany(a => a).AsObservableQuery().ToObservableView().ToBuffer(); }
public void SetupFilters() { source = new TestObservableCollection <string>("864".Select(i => i.ToString())); buffer = source.AsObservableQuery() .OrderByDescending(letter => letter) .AsObservableQuery() .ToObservableView() .ToBuffer(); }
public void NotYetImplemented_DoesntRemoveDuplicates() { source = new TestObservableCollection <string>("44".Select(i => i.ToString())); buffer = source.AsObservableQuery() .OrderByDescending(letter => letter) .AsObservableQuery() .ToObservableView() .ToBuffer(); Assert.AreEqual("44", string.Join("", buffer)); }
public void DoesNotEnumeratSourcesMoreThanOnce() { var c1 = new TestObservableCollection <string>() { "a", "b" }; var c2 = new TestObservableCollection <string>() { "a", "b", }; var buffer = c1.AsObservableQuery().Concat(c2).AsObservableQuery().ToObservableView().ToBuffer(); buffer.ToArray(); buffer.ToArray(); Assert.AreEqual(1, c1.EnumerationCount); Assert.AreEqual(1, c2.EnumerationCount); }
public void SetupFilters() { one = new TestObservableCollection <string>("0123456789".Select(i => i.ToString())); buffer = one.AsObservableQuery().Skip(5).AsObservableQuery().ToObservableView().ToBuffer(); }